Commit Graph

26040 Commits

Author SHA1 Message Date
Daniel Dunbar 29b8fb1771 tests: Force a triple to avoid wchar_t differences.
llvm-svn: 115970
2010-10-07 20:16:00 +00:00
Daniel Dunbar 355e850c6c tests: Tweak test to also match MSVC format.
llvm-svn: 115969
2010-10-07 20:14:30 +00:00
Fariborz Jahanian 4fc98f664b Start and end location of a property-dot syntax expression
must match start and end location of the expression
as expected by the rewriter client. Fixes // rdar: // 8520727

llvm-svn: 115934
2010-10-07 18:12:21 +00:00
Douglas Gregor c0f5dfc9d5 Don't force spell checking when code-completing. Let the client decide
llvm-svn: 115931
2010-10-07 18:03:24 +00:00
Daniel Dunbar 6036264fb4 Driver: When clang is built with a VENDOR set, include the base LLVM version in
the version information, to help prevent user confusion about vendor version
numbers vs. LLVM version numbers.

llvm-svn: 115915
2010-10-07 15:00:30 +00:00
Daniel Dunbar 7bb159b33c www: Grammar, etc.
llvm-svn: 115914
2010-10-07 15:00:19 +00:00
Chris Lattner 586c51e0b7 clang++ sorta works now
llvm-svn: 115903
2010-10-07 04:28:56 +00:00
Fariborz Jahanian c74073cd20 Patch for adding message to unavailable attribute.
And its documentation.
Finishes off // rdar: // 6734520.

llvm-svn: 115862
2010-10-06 23:12:32 +00:00
Tom Care ea53e82c78 UnreachableCodeChecker cleanup and improvements
- Fixed some iterator style issues
- Don't process blocks that have been visited already
- Fixed a case where a unreachable block cycle was not reported
- Minor test case changes
- Added one test case from flow-sensitive version of the check. More coming.

llvm-svn: 115861
2010-10-06 23:02:25 +00:00
Fariborz Jahanian 776653a70a Simplified code for deprecated attribute wih message a little.
llvm-svn: 115856
2010-10-06 22:20:08 +00:00
Fariborz Jahanian 55106310ae Add message to attribute(deprecated).
attribute(unavailable) to do next.
// rdar:// 6734520.

llvm-svn: 115842
2010-10-06 21:18:44 +00:00
Douglas Gregor a3d3ba1cac Fix a double-free error that can occur in rare cases where loading
of the precompiled preamble (or any PCH file it depends on) fails
during reparsing.

llvm-svn: 115838
2010-10-06 21:11:08 +00:00
Devang Patel 284fa417ec Mark FunctionNoProtoType's argument as unspecified parameters.
llvm-svn: 115834
2010-10-06 20:51:45 +00:00
John McCall 569eafce63 Re-enable EH cleanups to destroy __block variables, now that we have a moment to
deal with the consequences.  Fixes rdar://problem/8224178.

llvm-svn: 115816
2010-10-06 18:56:43 +00:00
Nick Lewycky 3005242401 Silence unused variable warning in Release builds.
llvm-svn: 115806
2010-10-06 18:37:39 +00:00
Devang Patel c0601d1e99 Do not emit subrange for incomplete array type.
This is tested by ptype.exp in gdb testsuite.

llvm-svn: 115805
2010-10-06 18:30:00 +00:00
Fariborz Jahanian 4801cc6315 Issue deprecated warning when typeof uses typedef
based on underlying type's deprecatedness.

llvm-svn: 115800
2010-10-06 17:00:02 +00:00
Douglas Gregor 3999e15d93 Reject the allocation of variably-modified types in C++ 'new'
expressions. Fixes PR8209 in the narrowest way possible. I'm still
considering whether I want to implement the extension that permits the
use of VLA types in a 'new' expression.

llvm-svn: 115790
2010-10-06 16:00:31 +00:00
Devang Patel 5b389f495b Remove unused argument.
llvm-svn: 115789
2010-10-06 15:58:57 +00:00
Francois Pichet f804a97d4f _inline is an alias for inline in MSVC.
llvm-svn: 115785
2010-10-06 13:02:48 +00:00
Chandler Carruth a64aedb34b Remove hard CRLF end-of-line markers from two files. These should be added
automatically when syncing due to the auto-props selecting svn:eol-style of
'native'.

llvm-svn: 115758
2010-10-06 06:50:05 +00:00
Nico Weber 9762e0a234 Add support for 4-byte UCNs like \U12345678. Warn about UCNs in c90 mode.
llvm-svn: 115743
2010-10-06 04:57:26 +00:00
Bill Wendling 964f521e85 Erm...this isn't the same as PR6658.
llvm-svn: 115737
2010-10-06 03:33:37 +00:00
Bill Wendling 6153d2c7bd MMX conversion work is done. We can remove the FIXMEs.
llvm-svn: 115736
2010-10-06 03:31:26 +00:00
Bill Wendling 8700d39139 Add same hack to mmx-builtins.c as in Headers/c89.c to get it to pass on Win32. PR6658.
llvm-svn: 115735
2010-10-06 03:31:09 +00:00
Anders Carlsson 0f7e94fd7b When checking for uninitialized fields in member initializers, special case static variables and enums. Fixes PR8075.
llvm-svn: 115732
2010-10-06 02:43:25 +00:00
John McCall 2a981c2056 Teach the driver to pass -fexceptions in Objective-C inputs on ARM.
I don't know when this stopped happening, but this seems to be the
right place to do it.

llvm-svn: 115730
2010-10-06 01:40:51 +00:00
John McCall 2551c1bbcd Provide a slightly specialized diagnostic for tautological comparisons
of an enum value.

llvm-svn: 115725
2010-10-06 00:25:24 +00:00
John McCall f449926a01 Use a more conventional/efficient implementation for isEnumeralType()
and isBuiltinType().

llvm-svn: 115724
2010-10-06 00:23:35 +00:00
Fariborz Jahanian b292e32fd2 Ue TagType, added a FIXME. Per John's comment.
llvm-svn: 115723
2010-10-06 00:23:25 +00:00
Fariborz Jahanian 121f5148fd Issue deprecated warning when typeof uses an
expression of deprecated type.

llvm-svn: 115713
2010-10-05 23:24:00 +00:00
John McCall 09d1369964 When instantiating a new-expression, force a rebuild if there were default
arguments in either the placement or constructor arguments.  This is
important if the default arguments refer to a declaration or create a
temporary.

llvm-svn: 115700
2010-10-05 22:36:42 +00:00
Fariborz Jahanian c080a333ce Method declaration and its implementation must match in all their types.
Previously, compiler warned only if it was unsafe if types
did not match. Fixes // rdar: //7933061

llvm-svn: 115683
2010-10-05 21:02:11 +00:00
John McCall 46b4dc32df ...without leaving a temporary file behind.
llvm-svn: 115671
2010-10-05 20:53:58 +00:00
John McCall 0ec01b0ca4 Er, this test should actually run IR generation.
llvm-svn: 115670
2010-10-05 20:53:00 +00:00
John McCall e5dd32da11 Teach PopCleanupBlock to correctly handle the possibility of branching through
a EH-only cleanup as part of a fallthrough branch-through.  That this happens
for this test case is actually a separate bug.

llvm-svn: 115668
2010-10-05 20:48:15 +00:00
Douglas Gregor 44e5c1f16c Serialize the "inline" bit for namespaces. Fixes <rdar://problem/8515069>.
llvm-svn: 115667
2010-10-05 20:41:58 +00:00
Douglas Gregor 9b3932c0bc Fix a marvelous chained AST writing bug, where we end up with the
following amusing sequence:
  - AST writing schedules writing a type X* that it had never seen
  before
  - AST writing starts writing another declaration, ends up
  deserializing X* from a prior AST file. Now we have two type IDs for
  the same type!
  - AST writer tries to write X*. It only has the lower-numbered ID
  from the the prior AST file, so references to the higher-numbered ID
  that was scheduled for writing go off into lalaland.

To fix this, keep the higher-numbered ID so we end up writing the type
twice. Since this issue occurs so rarely, and type records are
generally rather small, I deemed this better than the alternative: to
keep a separate mapping from the higher-numbered IDs to the
lower-numbered IDs, which we would end up having to check whenever we
want to deserialize any type.

Fixes <rdar://problem/8511624>, I think.

llvm-svn: 115647
2010-10-05 18:37:06 +00:00
Fariborz Jahanian fc8315f56a Fix a block rewriter bug where copy/dispose entries in
block descriptor for outer block was missing even though
the block was importing objects into its inner blocks.
//rdar://84995992

llvm-svn: 115644
2010-10-05 18:05:06 +00:00
Zhanyong Wan ea6d7f332d Fix handling of the 'Invalid' argument in SourceManager's methods (patch by Dean Sturtevant, reviewed by chandlerc and Sebastian Redl).
llvm-svn: 115638
2010-10-05 17:56:33 +00:00
Sebastian Redl 009e7f203f Give every file that ASTReader loads a type: module, PCH, precompiled preamble or main file. Base Decls' PCHLevel on this to make it more sane.
llvm-svn: 115626
2010-10-05 16:15:19 +00:00
Sebastian Redl 2c373b9876 Thread PerFileData through the ASTReader again, this time with the LLVM changes.
llvm-svn: 115625
2010-10-05 15:59:54 +00:00
Douglas Gregor 2c2c4cd9fd Register the __builtin_va_list_type node when we parse it, rather than
waiting until we think we need it: we didn't catch all of the places
where we actually needed it, and we probably wouldn't ever. Fixes a
C++ PCH crasher.

llvm-svn: 115621
2010-10-05 15:41:24 +00:00
Douglas Gregor aca68323f3 Remove a rogue typo
llvm-svn: 115618
2010-10-05 14:58:05 +00:00
Douglas Gregor 93269380e7 Register the __builtin_va_list_type node when we parse it, rather than
waiting until we think we need it: we didn't catch all of the places
where we actually needed it, and we probably wouldn't ever. Fixes a
C++ PCH crasher.

llvm-svn: 115617
2010-10-05 14:55:45 +00:00
Zhongxing Xu 614e17dddf * Simplify code
* Fix dump() to make it consistent with the test case.

llvm-svn: 115609
2010-10-05 08:38:06 +00:00
Marcin Swiderski 20b88739ed Added support for base and member destructors in destructor.
llvm-svn: 115592
2010-10-05 05:37:00 +00:00
Argyrios Kyrtzidis a992bbc08a Add test case for r115588.
llvm-svn: 115590
2010-10-05 03:15:43 +00:00
Argyrios Kyrtzidis dfbdfbba8f In Sema's TryRefInitWithConversionFunction, suppress user conversions for the overload candidates.
Fixes an infinite recursion in overload resolution for rdar://8499524.
Many thanks to Doug!

llvm-svn: 115588
2010-10-05 03:05:30 +00:00
John McCall 0077b22aa4 If we're resolving all outstanding fixups, and there are multiple fixups
for the same destination, then we must potentially rewrite the initial branch
of every fixup.  Without this patch, a short-circuit check meant to prevent
a switch case from being redundantly added was preventing later fixups from
being processed.  Fixes PR8175 (again).

llvm-svn: 115586
2010-10-05 02:33:56 +00:00