On Mon, Mar 5, 2012 at 12:38 AM, Daniel Veillard <veill...@redhat.com> wrote:
> On Thu, Mar 01, 2012 at 09:34:30AM -0800, Nico Weber wrote:
>> Hi,
>>
>> clang recently grew a warning on `for (...);`. The attached patch
>> fixes all two instances of this pattern in libxml. The changes don't
>> change any functionality.
>>
>> I put the ';' on the next line because that's what similar code in
>> uri.c already does, but just inserting a front of it gets rid of the
>> warning as well if you prefer that.
>
>  That's really weird. I though clang was parsing the C code,
> building a internal representation of the instructions and
> working from this. Adding a new line there should not change
> the expression graph and not change the output, so I'm starting
> to get worried about clang now :-)

Yes, it's a somewhat whacky heuristic. I think the idea is to find stuff like:

  while (...);
  {
  }

The warning was discussed here
http://comments.gmane.org/gmane.comp.compilers.clang.scm/46138 if
you're curious and/or want to chime in.

>  Patch is fine, pushed,

Thanks!

Nico
_______________________________________________
xml mailing list, project page  http://xmlsoft.org/
xml@gnome.org
http://mail.gnome.org/mailman/listinfo/xml

Reply via email to