Details
Details
- Reviewers
rsmith
Diff Detail
Diff Detail
Event Timeline
lib/Sema/SemaType.cpp | ||
---|---|---|
1564–1567 | How about just returning QualType() here? An invalid type should do a better job of suppressing follow-on diagnostics than an array-of-unexpected-size. |
lib/Sema/SemaType.cpp | ||
---|---|---|
1564–1567 | Returning QualType() also would prevent the crash, however it also causes a new error to be emitted. "initializer element is not a compile-time constant" on __builtin_offsetof(struct Chunk2, data). |
Comment Actions
When a too large array is requested, use QualType() to indicate there is not a valid type being created.
How about just returning QualType() here? An invalid type should do a better job of suppressing follow-on diagnostics than an array-of-unexpected-size.