edb5fdfb732d9b05f7f3c3248edea7b14331f4a4 |
|
15-Oct-2013 |
David Majnemer <david.majnemer@gmail.com> |
Sema: Consider it an error to apply __builtin_offsetof to a member in a virtual base icc 13 and g++ 4.9 both reject this while we would crash. Fixes PR17578. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@192674 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
ea0114313fbfba99f7067a2464c523e96a08e365 |
|
18-Oct-2011 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Perform lvalue-to-rvalue conversions on __builtin_offsetof array argument index before typechecking, as suggested by John. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@142308 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
19410a7e8ff6df550eb776574950d352a1de2bd8 |
|
05-Aug-2010 |
Eli Friedman <eli.friedman@gmail.com> |
PR7769: Fix references to anonymous structs/unions in base classes in offsetof expressions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110327 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
0fddb97901dbe36a8253dee29961cba8e0a87cf6 |
|
22-May-2010 |
Douglas Gregor <dgregor@apple.com> |
Implement support for variable length arrays in C++. VLAs are limited in several important ways: - VLAs of non-POD types are not permitted. - VLAs cannot be used in conjunction with C++ templates. These restrictions are intended to keep VLAs out of the parts of the C++ type system where they cause the most trouble. Fixes PR5678 and <rdar://problem/8013618>. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@104443 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
cc8a5d5f90bbbbcb46f342117b851b7e07ec34f1 |
|
29-Apr-2010 |
Douglas Gregor <dgregor@apple.com> |
Teach __builtin_offsetof to compute the offsets of members of base classes, since we only warn (not error) on offsetof() for non-POD types. We store the base path within the OffsetOfExpr itself, then evaluate the offsets within the constant evaluator. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102571 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
9d5d60ff8d7991234abcc6a9fe9903db930be0a1 |
|
29-Apr-2010 |
Douglas Gregor <dgregor@apple.com> |
Diagnose __builtin_offsetof expressions that refer to bit-fields git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102548 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
8ecdb65716cd7914ffb2eeee993fa9039fcd31e8 |
|
29-Apr-2010 |
Douglas Gregor <dgregor@apple.com> |
Completely reimplement __builtin_offsetof, based on a patch by Roberto Amadini. This change introduces a new expression node type, OffsetOfExpr, that describes __builtin_offsetof. Previously, __builtin_offsetof was implemented using a unary operator whose subexpression involved various synthesized array-subscript and member-reference expressions, which was ugly and made it very hard to instantiate as a template. OffsetOfExpr represents the AST more faithfully, with proper type source information and a more compact representation. OffsetOfExpr also has support for dependent __builtin_offsetof expressions; it can be value-dependent, but will never be type-dependent (like sizeof or alignof). This commit introduces template instantiation for __builtin_offsetof as well. There are two major caveats to this patch: 1) CodeGen cannot handle the case where __builtin_offsetof is not a constant expression, so it produces an error. So, to avoid regressing in C, we retain the old UnaryOperator-based __builtin_offsetof implementation in C while using the shiny new OffsetOfExpr implementation in C++. The old implementation can go away once we have proper CodeGen support for this case, which we expect won't cause much trouble in C++. 2) __builtin_offsetof doesn't work well with non-POD class types, particularly when the designated field is found within a base class. I will address this in a subsequent patch. Fixes PR5880 and a bunch of assertions when building Boost.Python tests. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102542 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
7c2342dd4c9947806842e5aca3d2bb2e542853c9 |
|
10-Mar-2010 |
John McCall <rjmccall@apple.com> |
When pretty-printing tag types, only print the tag if we're in C (and therefore not creating ElaboratedTypes, which are still pretty-printed with the written tag). Most of these testcase changes were done by script, so don't feel too sorry for my fingers. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98149 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
a5728872c7702ddd09537c95bc3cbd20e1f2fb09 |
|
15-Dec-2009 |
Daniel Dunbar <daniel@zuster.org> |
Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'. - This is designed to make it obvious that %clang_cc1 is a "test variable" which is substituted. It is '%clang_cc1' instead of '%clang -cc1' because it can be useful to redefine what gets run as 'clang -cc1' (for example, to set a default target). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91446 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
75b699a883ed02e9183cb5f4ad7086f4e3c6adf1 |
|
12-Dec-2009 |
Douglas Gregor <dgregor@apple.com> |
Suppress warnings and errors about certain uses of non-POD types (in __builtin_offsetof, passing through an ellipsis) when we're in an unevaluated context. This is the first part of the fix to PR5761, which deals with the simple case of an unevaluated context. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91210 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
16c5378c1e3af09a33604e096b3fe20742fc629d |
|
04-Dec-2009 |
Eli Friedman <eli.friedman@gmail.com> |
Make sure to call PerformObjectMemberConversion where necessary. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90555 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
c0d600c83a91b200616616f3982553c0ff42fcf3 |
|
03-May-2009 |
Eli Friedman <eli.friedman@gmail.com> |
Fix/re-enable test. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70800 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
9c2b34728b1a7c9df2df25fb5952dd33411a5a23 |
|
03-May-2009 |
Daniel Dunbar <daniel@zuster.org> |
Disable this test case, I'm tired of seeing red. :) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70799 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
5992e4a9cf7e2762a746a6d355dfab4598125012 |
|
02-May-2009 |
Anders Carlsson <andersca@mac.com> |
Fix a thinko and a test. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70637 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
f9b8bc662a84bb89a2d98530592f5d8fb6bee761 |
|
02-May-2009 |
Anders Carlsson <andersca@mac.com> |
Downgrade the invalid offsetof error to a warning. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70634 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|
6d7f149b0bff12e8f74c372e50b6e9a9ea980425 |
|
02-May-2009 |
Anders Carlsson <andersca@mac.com> |
It's an error to call offsetof on a non-POD type. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70595 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/test/SemaCXX/offsetof.cpp
|