george.burgess.iv closed this revision.
george.burgess.iv added a comment.
r245323
http://reviews.llvm.org/D12000
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
george.burgess.iv added inline comments.
Comment at: lib/AST/ExprConstant.cpp:6221-6223
@@ +6220,5 @@
+ //
+ // extern struct X { char buff[32]; int a, b, c; } *p;
+ // int a = __builtin_object_size(p-buff + 4, 3); // returns 28
+ // int b = __builtin_object_size(p-buff
george.burgess.iv updated the summary for this revision.
george.burgess.iv updated this revision to Diff 32333.
george.burgess.iv marked an inline comment as done.
george.burgess.iv added a comment.
Addressed feedback.
http://reviews.llvm.org/D12000
Files:
lib/AST/ExprConstant.cpp
rsmith accepted this revision.
rsmith added a reviewer: rsmith.
rsmith added a comment.
This revision is now accepted and ready to land.
LGTM with one more testcase :)
Comment at: lib/AST/ExprConstant.cpp:6243-6245
@@ +6242,5 @@
+ } else if (End.Designator.IsOnePastTheEnd) {
+
rsmith added a subscriber: rsmith.
Comment at: lib/AST/ExprConstant.cpp:6221-6223
@@ +6220,5 @@
+ //
+ // extern struct X { char buff[32]; int a, b, c; } *p;
+ // int a = __builtin_object_size(p-buff + 4, 3); // returns 28
+ // int b = __builtin_object_size(p-buff + 4,
george.burgess.iv created this revision.
george.burgess.iv added a subscriber: cfe-commits.
Attached is a fix for https://llvm.org/bugs/show_bug.cgi?id=15212 .
Summary: Tighten up some of the results for __builtin_object_size(ptr, type)
when given type == 1 or type == 3 + fixed a bug where we