|
Revision tags: llvmorg-3.0.0, llvmorg-3.0.0-rc4 |
|
| #
0f65d59e |
| 17-Nov-2011 |
David Blaikie <dblaikie@gmail.com> |
Include named unions in union member init checking
llvm-svn: 144883
|
|
Revision tags: llvmorg-3.0.0-rc3, llvmorg-3.0.0-rc2, llvmorg-3.0.0-rc1, llvmorg-2.9.0, llvmorg-2.9.0-rc3, llvmorg-2.9.0-rc2, llvmorg-2.9.0-rc1, llvmorg-2.8.0 |
|
| #
0f7e94fd |
| 06-Oct-2010 |
Anders Carlsson <andersca@mac.com> |
When checking for uninitialized fields in member initializers, special case static variables and enums. Fixes PR8075.
llvm-svn: 115732
|
|
Revision tags: llvmorg-2.8.0-rc3 |
|
| #
03f0e2b5 |
| 21-Sep-2010 |
Argyrios Kyrtzidis <akyrtzi@gmail.com> |
Do not warn with -Wuninitialized when the member is used in a sizeof or address-of expression. Fixes rdar://8331312.
llvm-svn: 114426
|
|
Revision tags: llvmorg-2.8.0-rc2, llvmorg-2.8.0-rc1, llvmorg-2.8.0-rc0 |
|
| #
3696dcb1 |
| 17-Aug-2010 |
John McCall <rjmccall@apple.com> |
Don't try to initialize a reference with a constructed temporary if either of the classes is invalid. A class is invalid if a base is invalid.
llvm-svn: 111227
|
| #
139e9621 |
| 30-Jun-2010 |
Chandler Carruth <chandlerc@gmail.com> |
Reapply r107235, this time with both my typo fixed, and a logical bug fixed. Previously we relied on the presence of a member which needs no initialization to prevent us from creating an additional i
Reapply r107235, this time with both my typo fixed, and a logical bug fixed. Previously we relied on the presence of a member which needs no initialization to prevent us from creating an additional initialization of the outer anonymous union field. We have already correctly marked that field as initialized by the member of the union (repeatedly due to the original bug this patch fixes) so we simply need to bail out.
llvm-svn: 107242
show more ...
|
| #
0e783c2e |
| 30-Jun-2010 |
Chandler Carruth <chandlerc@gmail.com> |
Revert r107235, it had a silly typo in it, and fixing the typo breaks something else. Get the build bots happy while I debug. Very sorry for the delay fixing this...
llvm-svn: 107239
|
| #
abb04f73 |
| 30-Jun-2010 |
Chandler Carruth <chandlerc@gmail.com> |
Fix PR7402: We were creating implicit member initializers for every field in an anonymous union under the presumption that they didn't do anything. While this is true, our checks for redundant initia
Fix PR7402: We were creating implicit member initializers for every field in an anonymous union under the presumption that they didn't do anything. While this is true, our checks for redundant initialization of an anonymous union still fire when these overlap with explicit user initialization. A cleaner approach is to avoid initializing multiple members of a union altogether, but this still is in a rather fuzzy are especially when C++0x allows non-POD types into unions.
llvm-svn: 107235
show more ...
|
|
Revision tags: llvmorg-2.7.0 |
|
| #
d7d4b204 |
| 25-Apr-2010 |
Anders Carlsson <andersca@mac.com> |
Land this test.
llvm-svn: 102292
|
| #
53e1ba94 |
| 25-Apr-2010 |
Anders Carlsson <andersca@mac.com> |
Revert enough of my patches to fix self-host again :(
llvm-svn: 102289
|
| #
90235beb |
| 24-Apr-2010 |
Anders Carlsson <andersca@mac.com> |
DefineImplicitCopyConstructor now uses SetBaseOrMemberInitializers to create implicit base initializers. (Member initializers are still handled by CodeGenFunction::SynthesizeCXXCopyConstructor for no
DefineImplicitCopyConstructor now uses SetBaseOrMemberInitializers to create implicit base initializers. (Member initializers are still handled by CodeGenFunction::SynthesizeCXXCopyConstructor for now).
llvm-svn: 102279
show more ...
|
| #
e87beb25 |
| 23-Apr-2010 |
John McCall <rjmccall@apple.com> |
Recommit my change to how C++ does elaborated type lookups, now with two bugfixes which fix selfhost and (hopefully) the nightly tests.
llvm-svn: 102198
|
| #
dca6be04 |
| 23-Apr-2010 |
Anders Carlsson <andersca@mac.com> |
Fix a think-o that broke self-host.
llvm-svn: 102165
|
| #
23eebd9c |
| 10-Apr-2010 |
John McCall <rjmccall@apple.com> |
Diagnose more cases of initializing distinct members of an anonymous union member. Use a better diagnostic for this case. Also fix a bug with nested anonymous structs/unions for -Wreorder; this la
Diagnose more cases of initializing distinct members of an anonymous union member. Use a better diagnostic for this case. Also fix a bug with nested anonymous structs/unions for -Wreorder; this last was PR6575.
llvm-svn: 100923
show more ...
|
| #
bb7b658a |
| 10-Apr-2010 |
John McCall <rjmccall@apple.com> |
Diagnose misordered initializers in constructor templates immediately instead of when they're instantiated. Merge the note into the -Wreorder warning; it doesn't really contribute much, and it was
Diagnose misordered initializers in constructor templates immediately instead of when they're instantiated. Merge the note into the -Wreorder warning; it doesn't really contribute much, and it was splitting a thought across diagnostics anyway. Don't crash in the parser when a constructor's initializers end in a comma and there's no body; the recovery here is still terrible, but anything's better than a crash.
llvm-svn: 100922
show more ...
|
| #
3155f573 |
| 09-Apr-2010 |
John McCall <rjmccall@apple.com> |
Turn access control on by default in -cc1. Remove -faccess-control from -cc1; add -fno-access-control. Make the driver pass -fno-access-control by default. Update a bunch of tests to be correct under
Turn access control on by default in -cc1. Remove -faccess-control from -cc1; add -fno-access-control. Make the driver pass -fno-access-control by default. Update a bunch of tests to be correct under access control.
llvm-svn: 100880
show more ...
|
| #
85f90559 |
| 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 wer
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.
llvm-svn: 98149
show more ...
|
| #
7ae2d775 |
| 31-Jan-2010 |
Douglas Gregor <dgregor@apple.com> |
Rework base and member initialization in constructors, with several (necessarily simultaneous) changes:
- CXXBaseOrMemberInitializer now contains only a single initializer rather than a set of
Rework base and member initialization in constructors, with several (necessarily simultaneous) changes:
- CXXBaseOrMemberInitializer now contains only a single initializer rather than a set of initialiation arguments + a constructor. The single initializer covers all aspects of initialization, including constructor calls as necessary but also cleanup of temporaries created by the initializer (which we never handled before!).
- Rework + simplify code generation for CXXBaseOrMemberInitializers, since we can now just emit the initializer as an initializer.
- Switched base and member initialization over to the new initialization code (InitializationSequence), so that it
- Improved diagnostics for the new initialization code when initializing bases and members, to match the diagnostics produced by the previous (special-purpose) code.
- Simplify the representation of type-checked constructor initializers in templates; instead of keeping the fully-type-checked AST, which is rather hard to undo at template instantiation time, throw away the type-checked AST and store the raw expressions in the AST. This simplifies instantiation, but loses a little but of information in the AST.
- When type-checking implicit base or member initializers within a dependent context, don't add the generated initializers into the AST, because they'll look like they were explicit.
- Record in CXXConstructExpr when the constructor call is to initialize a base class, so that CodeGen does not have to infer it from context. This ensures that we call the right kind of constructor.
There are also a few "opportunity" fixes here that were needed to not regress, for example:
- Diagnose default-initialization of a const-qualified class that does not have a user-declared default constructor. We had this diagnostic specifically for bases and members, but missed it for variables. That's fixed now.
- When defining the implicit constructors, destructor, and copy-assignment operator, set the CurContext to that constructor when we're defining the body.
llvm-svn: 94952
show more ...
|
| #
e1ac8d17 |
| 13-Jan-2010 |
John McCall <rjmccall@apple.com> |
Improve the reporting of non-viable overload candidates by noting the reason why the candidate is non-viable. There's a lot we can do to improve this, but it's a good start. Further improvements sh
Improve the reporting of non-viable overload candidates by noting the reason why the candidate is non-viable. There's a lot we can do to improve this, but it's a good start. Further improvements should probably be integrated with the bad-initialization reporting routines.
llvm-svn: 93277
show more ...
|
| #
fd0b2f8f |
| 06-Jan-2010 |
John McCall <rjmccall@apple.com> |
Improve the diagnostics used to report implicitly-generated class members as parts of overload sets. Also, refer to constructors as 'constructors' rather than functions.
Adjust a lot of tests.
llv
Improve the diagnostics used to report implicitly-generated class members as parts of overload sets. Also, refer to constructors as 'constructors' rather than functions.
Adjust a lot of tests.
llvm-svn: 92832
show more ...
|
| #
8fbe78f6 |
| 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 o
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).
llvm-svn: 91446
show more ...
|
| #
598caeee |
| 15-Nov-2009 |
Douglas Gregor <dgregor@apple.com> |
Don't gratuitously mark the default constructors of base or member initializers as used
llvm-svn: 88847
|
| #
d7686ef3 |
| 09-Nov-2009 |
Eli Friedman <eli.friedman@gmail.com> |
Unify the codepaths used to verify base and member initializers for explicitly and implicitly defined constructors. This has a number of benefits:
1. Less code.
2. Explicit and implicit constructo
Unify the codepaths used to verify base and member initializers for explicitly and implicitly defined constructors. This has a number of benefits:
1. Less code.
2. Explicit and implicit constructors get the same diagnostics.
3. The AST explicitly contains constructor calls from implicit default constructors. This allows handing some cases that previously weren't handled correctly in IRGen without any additional code. Specifically, implicit default constructors containing calls to constructors with default arguments are now handled correctly.
llvm-svn: 86500
show more ...
|
| #
e22a04ab |
| 04-Nov-2009 |
John McCall <rjmccall@apple.com> |
Diagnose using a field to initialize itself. Patch by Brandon Pearcy!
llvm-svn: 86061
|
|
Revision tags: llvmorg-2.6.0 |
|
| #
11289f42 |
| 09-Sep-2009 |
Mike Stump <mrs@apple.com> |
Remove tabs, and whitespace cleanups.
llvm-svn: 81346
|
| #
8b9575f2 |
| 24-Aug-2009 |
Douglas Gregor <dgregor@apple.com> |
Top-level semicolons are allowed in C++0x. Fixes PR4755.
llvm-svn: 79912
|