You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by Jens Geyer <je...@hotmail.com> on 2015/05/18 22:27:02 UTC

make style

Hi,

I’m not so sure if changing the style of certain constructs just for the sake of adhering to (more or less) arbitrary standards is really such a great idea. One example:

Original version

    to_string_mapping <<
                      indent() << "  }" << endl <<
                      indent() << "  return \"<UNSET>\"" << endl <<
                      indent() << "}" << endl;


After multiple “make style” and similar applied :

  to_string_mapping << indent() << "  }" << endl << indent() << "  return \"<UNSET>\"" << endl
                    << indent() << "}" << endl;

Is that really what we want? To me this only generates lots of noise in the code base and less readable code. To be honest, I have more and more problems to see the benefit of it. But since I am a constructive guy, I’d like to ask you: How can we improve the quality of those “Verschlimmbesserungen” [1]?

JensG

[1] That’s a german technical term. You may use Google Translate to find out what that means in your language.




Re: make style

Posted by Randy Abernethy <ra...@gmail.com>.
Verschlimmbesserungen is my new favorite word.

http://en.pons.com/translate/german-english/Verschlimmbesserungen

On Mon, May 18, 2015 at 2:07 PM, Konrad Grochowski <hc...@minions.org.pl>
wrote:

> Hi,
>
> I tried to apply it 'with common sense' but in some files there were just
> to many differences... If we would do it incrementally it would be better
> and easier to apply it on small changes.
>
> Make style was mostly introduced to help reorganize patches quickly.
>
> But I agree, it can be improved. We need to check what clang-format
> versions are available on CI right now - new one should support something
> like "//clang-format:off" comment. We could also check what new opts are
> available (I personally hate how clang-format makes short functions to
> single liners).
> Yet I believe, that consistent, even not perfect, but automatic tool is
> better than chaos.
>
> BTW: google translate fails ;)
>
> Regards,
> Konrad
>
>
> W dniu 2015-05-18 o 22:27, Jens Geyer pisze:
>
>  Hi,
>>
>> I’m not so sure if changing the style of certain constructs just for the
>> sake of adhering to (more or less) arbitrary standards is really such a
>> great idea. One example:
>>
>> Original version
>>
>>      to_string_mapping <<
>>                        indent() << "  }" << endl <<
>>                        indent() << "  return \"<UNSET>\"" << endl <<
>>                        indent() << "}" << endl;
>>
>>
>> After multiple “make style” and similar applied :
>>
>>    to_string_mapping << indent() << "  }" << endl << indent() << "
>> return \"<UNSET>\"" << endl
>>                      << indent() << "}" << endl;
>>
>> Is that really what we want? To me this only generates lots of noise in
>> the code base and less readable code. To be honest, I have more and more
>> problems to see the benefit of it. But since I am a constructive guy, I’d
>> like to ask you: How can we improve the quality of those
>> “Verschlimmbesserungen” [1]?
>>
>> JensG
>>
>> [1] That’s a german technical term. You may use Google Translate to find
>> out what that means in your language.
>>
>>
>>
>>
>>
>

Re: make style

Posted by Konrad Grochowski <hc...@minions.org.pl>.
Hi,

I tried to apply it 'with common sense' but in some files there were 
just to many differences... If we would do it incrementally it would be 
better and easier to apply it on small changes.

Make style was mostly introduced to help reorganize patches quickly.

But I agree, it can be improved. We need to check what clang-format 
versions are available on CI right now - new one should support 
something like "//clang-format:off" comment. We could also check what 
new opts are available (I personally hate how clang-format makes short 
functions to single liners).
Yet I believe, that consistent, even not perfect, but automatic tool is 
better than chaos.

BTW: google translate fails ;)

Regards,
Konrad


W dniu 2015-05-18 o 22:27, Jens Geyer pisze:
> Hi,
>
> I’m not so sure if changing the style of certain constructs just for the sake of adhering to (more or less) arbitrary standards is really such a great idea. One example:
>
> Original version
>
>      to_string_mapping <<
>                        indent() << "  }" << endl <<
>                        indent() << "  return \"<UNSET>\"" << endl <<
>                        indent() << "}" << endl;
>
>
> After multiple “make style” and similar applied :
>
>    to_string_mapping << indent() << "  }" << endl << indent() << "  return \"<UNSET>\"" << endl
>                      << indent() << "}" << endl;
>
> Is that really what we want? To me this only generates lots of noise in the code base and less readable code. To be honest, I have more and more problems to see the benefit of it. But since I am a constructive guy, I’d like to ask you: How can we improve the quality of those “Verschlimmbesserungen” [1]?
>
> JensG
>
> [1] That’s a german technical term. You may use Google Translate to find out what that means in your language.
>
>
>
>