[cfe-commits] [PATCH] Fix for crash on invalid in microsoft anonymous struct extension

Jason Haslam jason.haslam at gmail.com
Tue Jan 31 16:39:10 PST 2012


On Jan 31, 2012, at 5:01 PM, Nico Weber wrote:

> On Tue, Jan 31, 2012 at 3:53 PM, Jason Haslam <jason.haslam at gmail.com> wrote:
>> Ah, of course. Updated patch including test case attached. Thanks!
> 
> Would you want to setInvalidDecl() on a NULL RecordDef as well? When
> does this happen?

Probably yes. My understanding of this is pretty limited, but I'd guess that marking it invalid is probably appropriate. I've updated the patch to reflect this. As far as I can tell this only crashes when the struct is referenced through a typedef and the struct definition contains an error.

Jason

-------------- next part --------------
A non-text attachment was scrubbed...
Name: crash-on-invalid.diff
Type: application/octet-stream
Size: 1347 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120131/b4870d17/attachment.obj>


More information about the cfe-commits mailing list