[Ffmpeg-devel] [PATCH] move utf8 writing to libavutil

Måns Rullgård mru
Sun Jul 9 03:16:42 CEST 2006

Justin Ruggles <jruggle at earthlink.net> writes:

> M?ns Rullg?rd wrote:
>> Justin Ruggles <jruggle at earthlink.net> writes:
>>>+#define PUT_UTF8(val)\
>>>+    do {\
>>>+    if(val < 0x80){\
>> This could do with a little indentation.  Sure, it's not a big deal
>> being a macro definition and all.  It's only that bad indentation is
>> one of those things I just can't stand...
> Yeah, I debated both ways. I figured that if the do{}while(0) was added
> to GET_UTF8, indenting the whole block would be against the cosmetic
> changes policy...and I wanted the 2 macros to match... If the patch is
> okay otherwise, I don't have any strong feelings one way or the other.

The policy is self-contradicting.  It requires code to be correctly
indented, and also prohibits whitespace-only changes.  Complying with
both is sometimes difficult.

I can see the point with diffs being difficult to read if there are
large sections with indentation being the only change.  However, for
small pieces (<10 lines or so), I don't see it being a problem.

M?ns Rullg?rd
mru at inprovide.com

More information about the ffmpeg-devel mailing list