Aaron Ballman
804a7fb7ba
[C++11] Replacing DeclContext iterators using_directives_begin() and using_directives_end() with iterator_range using_directives(). Updating all of the usages of the iterators with range-based for loops, and removing the no-longer-needed iterator versions. Also used as an opportunity to normalize the name from getUsingDirectives() to using_directives().
...
llvm-svn: 204061
2014-03-17 17:14:12 +00:00
Aaron Ballman
5df6aa465e
[C++11] Replacing Scope iterators using_directives_begin() and using_directives_end() with iterator_range using_directives(). Updating all of the usages of the iterators with range-based for loops, and removing the no-longer-needed iterator versions.
...
llvm-svn: 204053
2014-03-17 17:03:37 +00:00
Aaron Ballman
35c5495bbb
[C++11] Replacing Scope iterators decl_begin() and decl_end() with iterator_range decls(). Updating all of the usages of the iterators with range-based for loops, and removing the no-longer-needed iterator versions.
...
llvm-svn: 204052
2014-03-17 16:55:25 +00:00
Aaron Ballman
83731469a1
[C++11] Replacing ObjCObjectPointerType iterators qual_begin() and qual_end() with iterator_range quals(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 204048
2014-03-17 16:14:00 +00:00
Aaron Ballman
1683f7baf6
[C++11] Replacing ObjCObjectType iterators qual_begin() and qual_end() with iterator_range quals(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 204047
2014-03-17 15:55:30 +00:00
Aaron Ballman
b088fbee3f
[C++11] Replacing FunctionProtoType iterators exception_begin() and exception_end() with iterator_range exceptions(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 204046
2014-03-17 15:38:09 +00:00
Aaron Ballman
40bd0aaf68
[C++11] Replacing FunctionProtoType iterators param_type_begin() and param_type_end() with iterator_range param_types(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 204045
2014-03-17 15:23:01 +00:00
Daniel Jasper
1fd6f1f8d6
clang-format: Indent from dict literal labels.
...
Before:
@{
NSFontAttributeNameeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee :
regularFont,
};
After:
@{
NSFontAttributeNameeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee :
regularFont,
};
llvm-svn: 204041
2014-03-17 14:32:47 +00:00
Aaron Ballman
c7e4e219b5
[C++11] Replacing CompoundStmt iterators body_begin() and body_end() with iterator_range body(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 204040
2014-03-17 14:19:37 +00:00
Richard Smith
d292b24f94
PR19152: If a variable template's type involves 'auto', instantiate the
...
initializer with the variable in order to determine the type.
llvm-svn: 204015
2014-03-16 01:00:40 +00:00
Benjamin Kramer
a939c23aec
Make some assertions on constant expressions static.
...
llvm-svn: 204012
2014-03-15 18:54:13 +00:00
Benjamin Kramer
329c596e58
Preprocessor: Clarify the ownership of the IncludeMacroStack with unique_ptr.
...
llvm-svn: 204007
2014-03-15 16:40:40 +00:00
Benjamin Kramer
a6f3950e39
Serialization: Directly compare objects instead of using a functor duplicating the compare operators.
...
No functionality change.
llvm-svn: 204006
2014-03-15 14:21:58 +00:00
Stephan Tolksdorf
e96f8b3774
Fix PR18806: Canonicalize the replacement type when deserializing a SubstTemplateTypeParmType
...
What's going on in the test case (without the patch applied) is this:
When the header is parsed, decltype(B()) is canonicalized to decltype(Y()),
because that was the first parsed equivalent decltype expression. Hence, the
TemplateSpecializationType for Id<decltype(B())> ends up with
SubstTemplateTypeParmType(T, decltype(Y())) as the AliasedType member.
When the PCH file is included and the AST reader reads Id<decltype(B())>, it
sees decltype(B()) before decltype(Y()). So, this time decltype(B()) ends up
being the canonical type for both decltypes, which leads to an assert violation
when the reader calls getSubstTemplateTypeParmType with the non-canonical
decltype(Y()) as the replacement type.
Reviewers: rsmith
Reviewed By: rsmith
CC: cfe-commits, aemerson
Differential Revision: http://llvm-reviews.chandlerc.com/D3073
llvm-svn: 204005
2014-03-15 10:23:27 +00:00
Benjamin Kramer
8cef8867ee
Remove dead functions from unreachable code analysis.
...
llvm-svn: 204004
2014-03-15 10:20:49 +00:00
Ted Kremenek
9dfe400dc2
-Wunreachable-code: treat 'const bool' locals as control values.
...
llvm-svn: 204001
2014-03-15 06:47:45 +00:00
Ted Kremenek
ad8753c00e
Further refine -Wunreachable-code groups so that -Wno-unreachable-code-break doesn't turn off all unreachable code warnings.
...
Also relax unreachable 'break' and 'return' to not check for being
preceded by a call to 'noreturn'. That turns out to not be so
interesting in practice.
llvm-svn: 204000
2014-03-15 05:47:06 +00:00
Craig Topper
fb6b25b5e4
[C++11] Add 'override' keyword to virtual methods that override their base class.
...
llvm-svn: 203999
2014-03-15 04:29:04 +00:00
Ted Kremenek
1a8641c1e7
Start breaking -Wunreachable-code up into different diagnostic groups.
...
Recent work on -Wunreachable-code has focused on suppressing uninteresting
unreachable code that center around "configuration values", but
there are still some set of cases that are sometimes interesting
or uninteresting depending on the codebase. For example, a dead
"break" statement may not be interesting for a particular codebase,
potentially because it is auto-generated or simply because code
is written defensively.
To address these workflow differences, -Wunreachable-code is now
broken into several diagnostic groups:
-Wunreachable-code: intended to be a reasonable "default" for
most users.
and then other groups that turn on more aggressive checking:
-Wunreachable-code-break: warn about dead break statements
-Wunreachable-code-trivial-return: warn about dead return statements
that return "trivial" values (e.g., return 0). Other return
statements that return non-trivial values are still reported
under -Wunreachable-code (this is an area subject to more refinement).
-Wunreachable-code-aggressive: supergroup that enables all these
groups.
The goal is to eventually make -Wunreachable-code good enough to
either be in -Wall or on-by-default, thus finessing these warnings
into different groups helps achieve maximum signal for more users.
TODO: the tests need to be updated to reflect this extra control
via diagnostic flags.
llvm-svn: 203994
2014-03-15 01:26:32 +00:00
Richard Smith
ae385084c5
Implement the MS extension __identifier properly: take a token and strip it of
...
its keywordliness.
llvm-svn: 203987
2014-03-15 00:06:08 +00:00
Fariborz Jahanian
e3b5c99fde
Objective-C. Redo turning off designated initialization warnings on
...
'init' methods which are unavailable. Subclasses of NSObject
have to implement such methods as a common pattern to prevent
user's own implementation. // rdar://16305460
llvm-svn: 203984
2014-03-14 23:30:18 +00:00
Richard Smith
594461f02c
Call RequireCompleteType when performing ADL even if the type is already
...
complete. We hook into this check from a couple of other places (modules,
debug info) so it's not OK to elide the check if the type was already
complete.
llvm-svn: 203978
2014-03-14 22:07:27 +00:00
Aaron Ballman
e6f465e51f
[C++11] Removing the found_decls_begin() and found_decls_end() APIs and replacing with a range-only found_decls() API.
...
llvm-svn: 203975
2014-03-14 21:38:48 +00:00
Richard Smith
7e34fbdaa0
Add two missing entries to the C++11 support page. Bump one relevant diagnostic
...
(for an integer too large for any signed type) from Warning to ExtWarn -- it's
ill-formed in C++11 and C99 onwards, and UB during translation in C89 and
C++98. Add diagnostic groups for two relevant diagnostics.
llvm-svn: 203974
2014-03-14 21:21:24 +00:00
Aaron Ballman
e42430ea31
[C++11] Removing the types_begin() and types_end() APIs and replacing with a range-only types() API.
...
llvm-svn: 203971
2014-03-14 21:11:14 +00:00
Aaron Ballman
bbc3121301
[C++11] Removing the local_import_begin() and local_import_end() APIs and replacing with a range-only local_imports() API. Privatizes the iterator class as well.
...
llvm-svn: 203970
2014-03-14 20:59:21 +00:00
Fariborz Jahanian
312104a716
Objective-C. Turn off designated initialization warnings on
...
'init' methods which are unavailable. Subclasses of NSObject
have to implement such methods as a common pattern to prevent
user's own implementation. // rdar://16305460
llvm-svn: 203966
2014-03-14 20:35:00 +00:00
Aaron Ballman
ba0238fa95
[C++11] Replacing CapturedStmt iterators capture_init_begin() and capture_init_end() with iterator_range capture_inits(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203959
2014-03-14 19:41:04 +00:00
Aaron Ballman
9371dd2287
[C++11] Replacing BlockDecl iterators capture_begin() and capture_end() with iterator_range captures(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203958
2014-03-14 18:34:04 +00:00
Fariborz Jahanian
6efab6eed7
Objective-C. Allow objc_designated_initializer for private
...
initializers; but only those declared in class extensions
(not in implementations). // rdar://16305347
llvm-svn: 203954
2014-03-14 18:19:46 +00:00
Aaron Ballman
c656303a2c
[C++11] Replacing CapturedStmt iterators capture_begin() and capture_end() with iterator_range captures(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203953
2014-03-14 18:08:33 +00:00
Hans Wennborg
73945149b7
Fix VS2012 build after r203881
...
llvm-svn: 203951
2014-03-14 17:45:06 +00:00
James Dennett
0492ef0e0b
Fix a crash (assertion failure) in EvaluateAsRValue.
...
Summary:
Gracefully fail to evaluate a constant expression if its type is
unknown, rather than failing an assertion trying to access the type.
Reviewers: klimek
Reviewed By: klimek
CC: chandlerc, cfe-commits
Differential Revision: http://llvm-reviews.chandlerc.com/D3075
llvm-svn: 203950
2014-03-14 17:44:10 +00:00
Timur Iskhodzhanov
f1749427c5
Fix PR19104: Incorrect handling of non-virtual calls of virtual methods
...
Reviewed at http://llvm-reviews.chandlerc.com/D3054
llvm-svn: 203949
2014-03-14 17:43:37 +00:00
Aaron Ballman
535bbcccb1
[C++11] Replacing DeclStmt iterators decl_begin() and decl_end() with iterator_range decls(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203947
2014-03-14 17:01:24 +00:00
Aaron Ballman
702fa310e5
[C++11] Replacing ClassTemplateDecl iterators spec_begin() and spec_end() with iterator_range specializations(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203940
2014-03-14 16:13:33 +00:00
Aaron Ballman
b8733c5ba4
[C++11] Replacing FunctionTemplateDecl iterators spec_begin() and spec_end() with iterator_range specializations(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203938
2014-03-14 16:05:56 +00:00
Aaron Ballman
2205d2a56a
[C++11] Replacing OMPThreadPrivateDecl and OMPClause iterators varlist_begin() and varlist_end() with iterator_range varlists(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203937
2014-03-14 15:55:35 +00:00
Fariborz Jahanian
a5a469efbd
Objective-C++ IRGen. Due to change to AST for initialization of c++11’s
...
data members by addition of CXXDefaultInitExpr node to the initializer expression,
it has broken treatment of arc code for such initializations. Reviewed by John McCall.
// rdar://16299964
llvm-svn: 203935
2014-03-14 15:40:54 +00:00
Aaron Ballman
576114e676
[C++11] Replacing DeclContext iterators lookups_begin() and lookups_end() with iterator_range lookups(). Similar for noload_lookups(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203933
2014-03-14 15:28:49 +00:00
Aaron Ballman
d6d25de46e
[C++11] Replacing ObjCImplementationDecl iterators ivar_begin() and ivar_end() with iterator_range ivars(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203932
2014-03-14 15:16:45 +00:00
Aaron Ballman
d85eff49a3
[C++11] Replacing ObjCCategoryDecl iterators propimpl_begin() and propimpl_end() with iterator_range property_impls(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203930
2014-03-14 15:02:45 +00:00
Daniel Jasper
5c77e39f2d
Don't verify module inclusions in assembler files.
...
llvm-svn: 203929
2014-03-14 14:53:17 +00:00
Aaron Ballman
865fbcdd8d
[C++11] Replacing ObjCCategoryDecl iterators ivar_begin() and ivar_end() with iterator_range ivars(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203924
2014-03-14 13:13:27 +00:00
Aaron Ballman
a73c85738c
[C++11] Replacing ObjCCategoryDecl iterators protocol_loc_begin() and protocol_loc_end() with iterator_range protocol_locs(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203923
2014-03-14 13:03:32 +00:00
Aaron Ballman
19a417699f
[C++11] Replacing ObjCCategoryDecl iterators protocol_begin() and protocol_end() with iterator_range protocols(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203922
2014-03-14 12:55:57 +00:00
Aaron Ballman
a964ec1f14
[C++11] Replacing ObjCProtocolDecl iterators protocol_loc_begin() and protocol_loc_end() with iterator_range protocol_locs(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203919
2014-03-14 12:38:50 +00:00
Christian Pirker
a74c7914ad
AArch64_be specific clang target settings
...
llvm-svn: 203918
2014-03-14 12:15:45 +00:00
Christian Pirker
f5164229f3
AArch64_be varargs processing for ARM ABI
...
llvm-svn: 203917
2014-03-14 11:51:06 +00:00
Benjamin Kramer
ca5ebafc9d
Remove unused typedef as pointed out by a GCC warning.
...
Yay for auto.
llvm-svn: 203912
2014-03-14 10:15:44 +00:00
Craig Topper
f85c6ce867
De-virtualize a method that doesn't override anything and has no overrides itself.
...
llvm-svn: 203895
2014-03-14 06:06:19 +00:00
Craig Topper
21beb40da5
Remove seemingly dead method. It was marked virtual but doesn't override anything and there don't seem to be any in tree callers.
...
llvm-svn: 203894
2014-03-14 06:04:02 +00:00
Craig Topper
b45acb8a16
[C++11] Add 'override' keyword to virtual methods that override their base class.
...
llvm-svn: 203893
2014-03-14 06:02:07 +00:00
Argyrios Kyrtzidis
6d0753d42a
[Modules] Emit the module file paths as dependencies of the PCH when we are building one.
...
This is because the PCH is tied to the module files, if one of the module files changes or gets removed
the build system should re-build the PCH file.
rdar://16321245
llvm-svn: 203885
2014-03-14 03:07:38 +00:00
Argyrios Kyrtzidis
68ccbe01b0
[Modules] Make sure that the synthesized file "__inferred_module.map" doesn't show up as dependency of a module file.
...
Follow-up for rdar://15459210
llvm-svn: 203882
2014-03-14 02:26:31 +00:00
Argyrios Kyrtzidis
ce9b49e5ec
Refactor ASTReader::readInputFileInfo to return a struct containing the related information.
...
No functionality change.
llvm-svn: 203881
2014-03-14 02:26:27 +00:00
Aaron Ballman
0f6e64d505
[C++11] Replacing ObjCProtocolDecl iterators protocol_begin() and protocol_end() with iterator_range protocols(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203863
2014-03-13 22:58:06 +00:00
Aaron Ballman
b4a5345598
[C++11] Replacing ObjCInterfaceDecl iterators known_extensions_begin() and known_extensions_end() with iterator_range known_extensions(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203857
2014-03-13 21:57:01 +00:00
Aaron Ballman
f53d8dd37d
[C++11] Replacing ObjCInterfaceDecl iterators visible_extensions_begin() and visible_extensions_end() with iterator_range visible_extensions(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203855
2014-03-13 21:47:07 +00:00
Aaron Ballman
15063e19c6
[C++11] Replacing ObjCInterfaceDecl iterators known_categories_begin() and known_categories_end() with iterator_range known_categories(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203854
2014-03-13 21:35:02 +00:00
Aaron Ballman
3fe486a332
[C++11] Replacing ObjCInterfaceDecl iterators visible_categories_begin() and visible_categories_end() with iterator_range visible_categories(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203851
2014-03-13 21:23:55 +00:00
Aaron Ballman
59abbd4d9b
[C++11] Replacing ObjCInterfaceDecl iterators ivar_begin() and ivar_end() with iterator_range ivars(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203849
2014-03-13 21:09:43 +00:00
Aaron Ballman
a9f49e394c
[C++11] Replacing ObjCInterfaceDecl iterators all_referenced_protocol_begin() and all_referenced_protocol_end() with iterator_range all_referenced_protocols(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203848
2014-03-13 20:55:22 +00:00
Aaron Ballman
e937888e1c
[C++11] Replacing ObjCInterfaceDecl iterators protocol_loc_begin() and protocol_loc_end() with iterator_range protocol_locs(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203847
2014-03-13 20:34:24 +00:00
Stephan Tolksdorf
232670fc05
Refactor InstantiatingTemplate constructors
...
This patch factors the bodies of 9 constructors out into a single initialization
method.
Reviewed By: rsmith
Differential Revision: http://llvm-reviews.chandlerc.com/D3059
llvm-svn: 203846
2014-03-13 20:34:22 +00:00
Stephan Tolksdorf
eb7708d07a
Add SourceRange to err_not_tag_in_scope diagnostic in TreeTransform<...>::RebuildDependentNameType
...
Apparently the FIXME was overlooked when the source location information was
made available to the function.
Reviewed By: rsmith
Differential Revision: http://llvm-reviews.chandlerc.com/D3058
llvm-svn: 203845
2014-03-13 20:34:03 +00:00
Aaron Ballman
a49c5064a1
[C++11] Replacing ObjCInterfaceDecl iterators protocol_begin() and protocol_end() with iterator_range protocols(). Updating all of the usages of the iterators with range-based for loops.
...
Drive-by fixing some incorrect types where a for loop would be improperly using ObjCInterfaceDecl::protocol_iterator. No functional changes in these cases.
llvm-svn: 203842
2014-03-13 20:29:09 +00:00
Aaron Ballman
e8a7dc9889
[C++11] Replacing ObjCContainerDecl iterators classmeth_begin() and classmeth_end() with iterator_range class_methods(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203840
2014-03-13 20:11:06 +00:00
Aaron Ballman
f26acce6f7
[C++11] Replacing ObjCContainerDecl iterators instmeth_begin() and instmeth_end() with iterator_range instance_methods(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203839
2014-03-13 19:50:17 +00:00
Tim Northover
514fc61c09
CodeGen: use symbolic enumerators for memory order
...
It makes the code clearer and less error-prone to use our (already
known) special values for the various memory order cases.
llvm-svn: 203838
2014-03-13 19:25:52 +00:00
Tim Northover
9c177223bc
CodeGen: make use of weaker failure orders on cmpxchg.
...
This makes Clang take advantage of the recent IR addition of a
"failure" memory ordering requirement. As with the "success" ordering,
we try to emit just a single version if the expression is constant,
but fall back to runtime detection (to allow optimisation across
function-call boundaries).
rdar://problem/15996804
llvm-svn: 203837
2014-03-13 19:25:48 +00:00
Aaron Ballman
d174edffa0
Renaming the recently-created (r203830) props() range API to properties() for clarity.
...
llvm-svn: 203835
2014-03-13 19:11:50 +00:00
Aaron Ballman
aff18c0446
[C++11] Replacing ObjCContainerDecl iterators meth_begin() and meth_end() with iterator_range methods(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203832
2014-03-13 19:03:34 +00:00
Aaron Ballman
dc4bea4676
[C++11] Replacing ObjCContainerDecl iterators prop_begin() and prop_end() with iterator_range props(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203830
2014-03-13 18:47:37 +00:00
Aaron Ballman
91cdc28d93
[C++11] Replacing UsingDecl iterators shadow_begin() and shadow_end() with iterator_range shadows(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203825
2014-03-13 18:07:29 +00:00
Jordan Rose
821a3a0f77
[analyzer] Warn when passing pointers to const but uninitialized memory.
...
Passing a pointer to an uninitialized memory buffer is normally okay,
but if the function is declared to take a pointer-to-const then it's
very unlikely it will be modifying the buffer. In this case the analyzer
should warn that there will likely be a read of uninitialized memory.
This doesn't check all elements of an array, only the first one.
It also doesn't yet check Objective-C methods, only C functions and
C++ methods.
This is controlled by a new check: alpha.core.CallAndMessageUnInitRefArg.
Patch by Per Viberg!
llvm-svn: 203822
2014-03-13 17:55:39 +00:00
Aaron Ballman
9bc5f36099
[C++11] Replacing ObjCImplementationDecl iterators init_begin() and init_end() with iterator_range inits(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203820
2014-03-13 17:35:02 +00:00
Aaron Ballman
0ad78303de
[C++11] Replacing CXXRecordDecl iterators init_begin() and init_end() with iterator_range inits(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203819
2014-03-13 17:34:31 +00:00
Aaron Ballman
6def98ab5f
[C++11] Replacing CXXRecordDecl iterators capture_begin() and capture_end() with iterator_range captures(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203817
2014-03-13 17:08:33 +00:00
Hans Wennborg
a316933e09
MS intrinsics: __interlockedbittestandset(64) (PR19054)
...
llvm-svn: 203816
2014-03-13 17:05:09 +00:00
Aaron Ballman
522a6ddf9e
[C++11] Replacing CXXRecordDecl iterators friend_begin() and friend_end() with iterator_range friends(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203815
2014-03-13 17:00:06 +00:00
Aaron Ballman
2a4bd6d189
[C++11] Replacing CXXRecordDecl iterators ctor_begin() and ctor_end() with iterator_range ctors(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203814
2014-03-13 16:51:27 +00:00
Ben Langmuir
d285c50390
Prevent outputting HeaderFileInfos for files not used as headers
...
When building an AST file, we don't want to output HeaderFileInfo
structures for files that are not actually used as headers in the
current context. This can lead to assuming that unrelated files have
include counts of 0, defeating multiple-include prevention.
This is accomplished by adding an IsValid bit to the HFI.
llvm-svn: 203813
2014-03-13 16:46:36 +00:00
Aaron Ballman
2b124d1a5d
[C++11] Replacing CXXRecordDecl iterators method_begin() and method_end() with iterator_range methods(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203812
2014-03-13 16:36:16 +00:00
Aaron Ballman
445a939db8
[C++11] Replacing CXXRecordDecl iterators vbases_begin() and vbases_end() with iterator_range vbases(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203808
2014-03-13 16:15:17 +00:00
Rafael Espindola
93c7a6532e
Simplify code. No functionality change.
...
llvm-svn: 203804
2014-03-13 15:47:50 +00:00
Aaron Ballman
574705ed7f
[C++11] Replacing CXXRecordDecl iterators bases_begin() and bases_end() with iterator_range bases(). Updating all of the usages of the iterators with range-based for loops.
...
llvm-svn: 203803
2014-03-13 15:41:46 +00:00
Alexander Kornienko
c2ee9cf861
Remove an unnecessary check for FormatTok not being null.
...
Summary:
This check hints clang analyzer, that FormatTok may be null, and it
reports a null pointer dereference error:
http://buildd-clang.debian.net/scan-build/report-827c64.html#Path28
Reviewers: djasper
Reviewed By: djasper
CC: cfe-commits, klimek
Differential Revision: http://llvm-reviews.chandlerc.com/D3040
llvm-svn: 203800
2014-03-13 13:59:48 +00:00
Daniel Jasper
ac7e34e778
clang-format: Prevent ObjC code from confusing the braced-init detection
...
This was leading to bad formatting, e.g.:
Before:
f(^{
@autoreleasepool {
if (a) {
g();
}
}
});
After:
f(^{
@autoreleasepool {
if (a) {
g();
}
}
});
llvm-svn: 203777
2014-03-13 10:11:17 +00:00
Craig Topper
2e5c11ff5c
[C++11] Add 'override' keyword to virtual methods that override their base class.
...
llvm-svn: 203769
2014-03-13 08:12:15 +00:00
Craig Topper
456705304a
De-virtualize a method. It's called through template magic and doesn't override anything.
...
llvm-svn: 203764
2014-03-13 07:14:47 +00:00
Craig Topper
34d8e21d32
Remove unreachable PragmaCaptured method. It's not a real PPCallback.
...
llvm-svn: 203759
2014-03-13 06:19:24 +00:00
Craig Topper
afa7cb3aa5
[C++11] Add 'override' keyword to virtual methods that override their base class.
...
llvm-svn: 203758
2014-03-13 06:07:04 +00:00
Craig Topper
3e89dfee00
[C++11] Add 'override' keyword to virtual methods that override their base class.
...
llvm-svn: 203746
2014-03-13 02:13:41 +00:00
Joerg Sonnenberger
52be0b4cf4
Always use --eh-frame-hdr on NetBSD, even for -static.
...
llvm-svn: 203742
2014-03-13 00:42:01 +00:00
Richard Smith
aae4058453
PR18275: If a member function of a class template is declared with a
...
const-qualified parameter type and the defined with a non-const-qualified
parameter type, the parameter is not const inside its body. Ensure that
the type we use when instantiating the body is the right one. Patch by
suyog sarda!
This is still rather unsatisfactory; it seems like it might be better to
instantiate at least the function parameters, and maybe the complete function
declaration, when we instantiate the definition for such a member function
(instead of reusing the declaration from inside the instantiated class
definition).
llvm-svn: 203741
2014-03-13 00:28:45 +00:00
Richard Smith
5b5d21ea1a
Only allow streaming exactly type 'bool' to a DiagnosticBuilder, not anything
...
that implicitly converts to 'bool' (such as pointers, and the first operand of
?:). Clean up issues found by this. Patch by Stephan Tolksdorf!
llvm-svn: 203735
2014-03-12 23:36:42 +00:00
Richard Smith
8e6002f3bd
Fix crash if delayed template parsing meets an erroneous trailing return type.
...
Based on a patch and test by Stephan Tolksdorf! Refactoring and fixing adjacent
brokenness by me.
llvm-svn: 203733
2014-03-12 23:14:33 +00:00
Hans Wennborg
d9be72ec44
MS intrinsics: implement the __movs and __stos intrinsics (PR19054)
...
llvm-svn: 203722
2014-03-12 22:00:32 +00:00
Hans Wennborg
a4421e03fa
MS intrinsics: implement __readgs{byte,word,dword,qword} (PR19054)
...
llvm-svn: 203715
2014-03-12 21:09:05 +00:00