You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@lucy.apache.org by "Marvin Humphrey (Resolved) (JIRA)" <ji...@apache.org> on 2011/11/17 03:13:51 UTC
[lucy-issues] [jira] [Resolved] (LUCY-145) Refactor away C89 excess braces
[ https://issues.apache.org/jira/browse/LUCY-145?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marvin Humphrey resolved LUCY-145.
----------------------------------
Resolution: Fixed
Assignee: Marvin Humphrey
Great job, Richard! Your patch met the requirements for this
issue precisely. I applied it verbatim, then followed up
with some minor whitespace changes.
> Refactor away C89 excess braces
> -------------------------------
>
> Key: LUCY-145
> URL: https://issues.apache.org/jira/browse/LUCY-145
> Project: Lucy
> Issue Type: Sub-task
> Reporter: Marvin Humphrey
> Assignee: Marvin Humphrey
> Priority: Trivial
> Attachments: lucy_patch-145.diff
>
>
> Because C89 does not allow mixed declarations and code, we have occasionally
> used bare braces to create new scopes solely for the purpose of declaring a
> variable or two. In some cases, this was appropriate to limit the scope of a
> short lived variable in the midst of a long function, but there were other
> cases when we were just declaring a return value or such towards the end and
> C89 forced the issue.
> To find candidates for review, use the following command:
> {noformat}
> grep -r "^ \+{ *$" lucy/ | grep -v -e "svn\|charmonizer\|modules\|\.pm"
> {noformat}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira