My First patch

Lubomir I. Ivanov neolit123 at gmail.com
Sat Mar 1 11:32:24 PST 2014


hello,

On 1 March 2014 19:59, Gopichand Paturi <gopichandpaturi at gmail.com> wrote:
> Hi Dirkhh and others,
> I am submitting my first patch(my first one ever). This is very minor and
> acute.
>

the patch has trailing whitespace, which should be removed.
another small issue is the lack of space before the '{' here:
if (he > maxhe){

> I am sending this,as an improvement to the existing code since
> goto is not preferred as a reliable keyword in software development process.
>

goto is perfectly fine in a lot of cases and doesn't obfuscate the
code that much if used wisely.
as you can see your patch removes 3 lines, but adds 6.

> I can change the logic regarding goto in all the cpp files in the existing
> codebase. I am good at C++, so I am sure that I will not disturb the logic
> part.
>
> If I am not sure,I will ensure not to touch that part of code.
> This(removing goto) would make the code base more reliable. Let me know your
> feedback.
>

we kind off do not mind forward goto's for error cases near the return
and such, but if there is backward goto then perhaps that same block
should be a do...while().

thanks
lubomir
--


More information about the subsurface mailing list