6bcf27bb9a4b5c3f79cb44c0e4654a6d7619ad89 |
29-May-2014 |
Stephen Hines <srhines@google.com> |
Update Clang for 3.5 rebase (r209713). Change-Id: I8c9133b0f8f776dc915f270b60f94962e771bc83
ver.match/over.match.funcs/over.match.oper/p3.cpp
|
72a36a14b10c18bc72bf0472dc29e86327615c26 |
14-Aug-2013 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Don't produce duplicate notes if we have deduction failure notes when resolving the address of an overloaded function template. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@188334 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2.cpp
|
4384712b3a0aedd7c68d6abdb0407850f7b46c8b |
20-Jul-2013 |
Larisse Voufo <lvoufo@google.com> |
FIXME fix: improving diagnostics for template arguments deduction of class templates and explicit specializations This patch essentially removes all the FIXMEs following calls to DeduceTemplateArguments() that want to keep track of deduction failure info. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@186730 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2.cpp
|
8c5d4078bb40642847164e7613828262d32db973 |
20-Jul-2013 |
Larisse Voufo <lvoufo@google.com> |
Revert "Use function overloading instead of template specialization for diagnosis of bad template argument deductions." This reverts commit a730f548325756d050d4caaa28fcbffdae8dfe95. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@186729 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2.cpp
|
a730f548325756d050d4caaa28fcbffdae8dfe95 |
20-Jul-2013 |
Larisse Voufo <lvoufo@google.com> |
Use function overloading instead of template specialization for diagnosis of bad template argument deductions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@186727 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2.cpp
|
c2fe81898b1b3b948791ca4ababd3d495601f22a |
04-Jun-2013 |
David Blaikie <dblaikie@gmail.com> |
Bound member function diagnostic - suggest no-args calls and note overload candidates Still missing cases for templates, but this is a step in the right direction. Also omits suggestions that would be ambiguous (eg: void func(int = 0); + void func(float = 0); func;) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@183173 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
7e0c22714e4750a2f730035957f9bb678ae681c0 |
10-Apr-2013 |
Douglas Gregor <dgregor@apple.com> |
<rdar://problem/13605348> Don't consider invalid user-defined literal operators during overload resolution. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@179150 91177308-0d34-0410-b5e6-96231b3b80d8
ver.oper/over.literal/p2.cpp
|
c7629d941557f7179eb8fa8a2e2a74d749cbaf7c |
24-Jan-2013 |
Jordan Rose <jordan_rose@apple.com> |
Handle universal character names and Unicode characters outside of literals. This is a missing piece for C99 conformance. This patch handles UCNs by adding a '\\' case to LexTokenInternal and LexIdentifier -- if we see a backslash, we tentatively try to read in a UCN. If the UCN is not syntactically well-formed, we fall back to the old treatment: a backslash followed by an identifier beginning with 'u' (or 'U'). Because the spelling of an identifier with UCNs still has the UCN in it, we need to convert that to UTF-8 in Preprocessor::LookUpIdentifierInfo. Of course, valid code that does *not* use UCNs will see only a very minimal performance hit (checks after each identifier for non-ASCII characters, checks when converting raw_identifiers to identifiers that they do not contain UCNs, and checks when getting the spelling of an identifier that it does not contain a UCN). This patch also adds basic support for actual UTF-8 in the source. This is treated almost exactly the same as UCNs except that we consider stray Unicode characters to be mistakes and offer a fixit to remove them. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@173369 91177308-0d34-0410-b5e6-96231b3b80d8
ver.oper/over.literal/p8.cpp
|
aa9a8ce5d31975900c7243b1508f5111baddacbe |
20-Oct-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
DR1473: Do not require a space between operator"" and the ud-suffix in a literal-operator-id. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166373 91177308-0d34-0410-b5e6-96231b3b80d8
ver.oper/over.literal/p8.cpp
|
8e8fb3be5bd78f0564444eca02b404566a5f3b5d |
19-Oct-2012 |
Andy Gibbs <andyg1001@hotmail.co.uk> |
Prior to adding the new "expected-no-diagnostics" directive to VerifyDiagnosticConsumer, make the necessary adjustment to 580 test-cases which will henceforth require this new directive. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166280 91177308-0d34-0410-b5e6-96231b3b80d8
ver.built/p23.cpp
ver.built/p25.cpp
ver.match/over.match.best/over.ics.rank/p3-0x.cpp
ver.match/over.match.best/p1.cpp
ver.match/over.match.funcs/over.match.oper/p3.cpp
ver.match/over.match.funcs/p4-0x.cpp
ver.oper/over.literal/p7.cpp
|
97c6739a1e74a3131261081054ff4a75e4e3b64c |
18-Sep-2012 |
Eli Friedman <eli.friedman@gmail.com> |
Fix a small bug in the way we handle builtin candidates for relational operators of enumeration type. From the gcc testsuite. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@164171 91177308-0d34-0410-b5e6-96231b3b80d8
ver.built/p1.cpp
ver.match/over.match.funcs/over.match.oper/p3.cpp
|
e14ba2cec3807df892917171b590bac25b779b46 |
04-Apr-2012 |
John McCall <rjmccall@apple.com> |
When computing the conversion sequence in overload resolution for converting an empty list to a scalar, be sure to initialize the source and destination types so that comparison of conversion sequences will work in case there are multiple viable candidates. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@153993 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.best/over.best.ics/over.ics.list/p6.cpp
|
1d23c4219527d9a2bc75f5cdb1ffcaefb8bcc61b |
15-Mar-2012 |
David Blaikie <dblaikie@gmail.com> |
Unpluralize -Wfoo-conversions warnings for consistency. Err on the side of brevity and rename (while providing aliases for the original name) -Wbool-conversions, -Wint-conversions, and -Wvector-conversions for consistency with constant, literal, string, and sign conversion warnings. And name the diagnostic groups explicitly while I'm here rather than rewriting the string in the groups and sema td files. Curiously, vector-conversion is not under -Wconversion. Perhaps it should be. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152776 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
e5658f0ab2a6f8fea258adb64edbb8485bb21dee |
10-Mar-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
PR12225: The requirement that literal operators be namespace-scope functions does not imply that such functions can't be declared at block scope. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152509 91177308-0d34-0410-b5e6-96231b3b80d8
ver.oper/over.literal/p2.cpp
|
3a5032b89df601ab2e0c5c7e9667db2301bf10cf |
09-Mar-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Literal operator suffixes and regular names live in separate namespaces. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152395 91177308-0d34-0410-b5e6-96231b3b80d8
ver.oper/over.literal/p2.cpp
|
a9e88b2549add9766382c70d270dfd89fa33f7cf |
09-Mar-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Literal operators can't have default arguments. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152394 91177308-0d34-0410-b5e6-96231b3b80d8
ver.oper/over.literal/p3.cpp
|
2fb4ae36825ca3a0cbe7e845c5747062870066be |
08-Mar-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Implement C++11 [lex.ext]p10 for string and character literals: a ud-suffix not starting with an underscore is ill-formed. Since this rule rejects programs that were using <inttypes.h>'s macros, recover from this error by treating the ud-suffix as a separate preprocessing-token, with a DefaultError ExtWarn. The approach of treating such cases as two tokens is under discussion for standardization, but is in any case a conforming extension and allows existing codebases to keep building while the committee makes up its mind. Reword the warning on the definition of literal operators not starting with underscores (which are, strangely, legal) to more explicitly state that such operators can't be called by literals. Remove the special-case diagnostic for hexfloats, since it was both triggering in the wrong cases and incorrect. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152287 91177308-0d34-0410-b5e6-96231b3b80d8
ver.oper/over.literal/p8.cpp
|
99831e4677a7e2e051af636221694d60ba31fcdb |
06-Mar-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
User-defined literals: reject string and character UDLs in all places where the grammar requires a string-literal and not a user-defined-string-literal. The two constructs are still represented by the same TokenKind, in order to prevent a combinatorial explosion of different kinds of token. A flag on Token tracks whether a ud-suffix is present, in order to prevent clients from needing to look at the token's spelling. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152098 91177308-0d34-0410-b5e6-96231b3b80d8
ver.oper/over.literal/p8.cpp
|
5cc2c6eb67b6e5361bbe96f79b519fd62ec666d6 |
05-Mar-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Lexing support for user-defined literals. Currently these lex as the same token kinds as the underlying string literals, and we silently drop the ud-suffix; those issues will be fixed by subsequent patches. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152012 91177308-0d34-0410-b5e6-96231b3b80d8
ver.oper/over.literal/p5.cpp
ver.oper/over.literal/p8.cpp
|
b4a7b1e587a232c95d02a8ca10eeba60164fbba1 |
04-Mar-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Add tests for [over.literal]. Fix a few bugs which were exposed by the tests. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151997 91177308-0d34-0410-b5e6-96231b3b80d8
ver.oper/over.literal/p2.cpp
ver.oper/over.literal/p3.cpp
ver.oper/over.literal/p5.cpp
ver.oper/over.literal/p6.cpp
ver.oper/over.literal/p7.cpp
ver.oper/over.literal/p8.cpp
|
9b42afdccc9f4b32ed4f83492f87e2cd0518f9f3 |
25-Feb-2012 |
Douglas Gregor <dgregor@apple.com> |
Add test for C++ DR899. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151411 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.funcs/over.match.copy/p1.cpp
|
ed878af7914df535b32d64f555fa118413186672 |
25-Feb-2012 |
Douglas Gregor <dgregor@apple.com> |
Implement C++11 [over.match.copy]p1b2, which allows the use of explicit conversion functions to initialize the argument to a copy/move constructor that itself is the subject of direct initialization. Since we don't have that much context in overload resolution, we end up threading more flags :(. Fixes <rdar://problem/10903741> / PR10456. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151409 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.funcs/over.match.copy/p1.cpp
|
2fe9b7fb07dff15dd15dd8755a9a9e6de0fe46fc |
15-Dec-2011 |
Richard Trieu <rtrieu@google.com> |
Modify how the -verify flag works. Currently, the verification string and diagnostic message are compared. If either is a substring of the other, then no error is given. This gives rise to an unexpected case: // expect-error{{candidate function has different number of parameters}} will match the following error messages from Clang: candidate function has different number of parameters (expected 1 but has 2) candidate function has different number of parameters It will also match these other error messages: candidate function function has different number of parameters number of parameters This patch will change so that the verification string must be a substring of the diagnostic message before accepting. Also, all the failing tests from this change have been corrected. Some stats from this cleanup: 87 - removed extra spaces around verification strings 70 - wording updates to diagnostics 40 - extra leading or trailing characters (typos, unmatched parens or quotes) 35 - diagnostic level was included (error:, warning:, or note:) 18 - flag name put in the warning (-Wprotocol) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146619 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
2def77399ab3088106a2d61372344f5b7104e1a2 |
09-Dec-2011 |
David Blaikie <dblaikie@gmail.com> |
Add notes for suppressing and (if it's a zero-arg function returning bool) fixing the function-to-bool conversion warning. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146280 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
e14ca9f509dc22d8fcc5d21d70d28a5848983b42 |
05-Dec-2011 |
Lang Hames <lhames@gmail.com> |
Add a warning for implicit conversion from function literals (and static methods) to bool. E.g. void foo() {} if (f) { ... // <- Warns here. } Only applies to non-weak functions, and does not apply if the function address is taken explicitly with the addr-of operator. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145849 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
5acb0c98b363400f6ade0ae7250f0102224e806b |
17-Oct-2011 |
John McCall <rjmccall@apple.com> |
Teach the ARC compiler to not require __bridge casts when passing/receiving CF objects at +0 to/from Objective-C methods or audited C functions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@142219 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
762bb9d0ad20320b9f97a841dce57ba5e8e48b07 |
14-Oct-2011 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Update all tests other than Driver/std.cpp to use -std=c++11 rather than -std=c++0x. Patch by Ahmed Charles! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141900 91177308-0d34-0410-b5e6-96231b3b80d8
ver.built/p23.cpp
ver.built/p25.cpp
ver.load/p2-0x.cpp
ver.match/over.match.best/over.best.ics/over.ics.user/p3-0x.cpp
ver.match/over.match.best/over.ics.rank/p3-0x.cpp
ver.match/over.match.funcs/p4-0x.cpp
|
6dbba4fc128e2e2f5b26be996392bd32c0707f13 |
12-Oct-2011 |
John McCall <rjmccall@apple.com> |
Catch placeholder types in DefaultLvalueConversion and DefaultFunctionArrayLvalueConversion. To prevent significant regression for should-this-be-a-call fixits, and to repair some such regression from the introduction of bound member placeholders, make those placeholder checks try to build calls appropriately. Harden the build-a-call logic while we're at it. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141738 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
25aaff9cf8a66bc236e5ccaf6183d11c14674cd3 |
10-Oct-2011 |
Douglas Gregor <dgregor@apple.com> |
Always add the built-in overload candidates for operators &&, ||, and !. Fixes PR9865. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141537 91177308-0d34-0410-b5e6-96231b3b80d8
ver.built/p23.cpp
|
864c041e118155c2b1ce0ba36942a3da5a4a055e |
26-Apr-2011 |
John McCall <rjmccall@apple.com> |
Make yet another placeholder type, this one marking that an expression is a bound member function, i.e. something of the form 'x.f' where 'f' is a non-static member function. Diagnose this in the general case. Some of the new diagnostics are probably worse than the old ones, but we now get this right much more universally, and there's certainly room for improvement in the diagnostics. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130239 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
fb8721ce4c6fef3739b1cbd1e38e3f1949462033 |
10-Apr-2011 |
John McCall <rjmccall@apple.com> |
Simplify calling CheckPlaceholderExpr, converge on it in a few places, and move a vector-splat check to follow l-value conversion. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129254 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
90434238b7edfc806437f1d40742a60ff92fbf6a |
29-Mar-2011 |
Chandler Carruth <chandlerc@gmail.com> |
Fix a bug in how we were resolving the address of overloaded functions when the resolution took place due to a single template specialization being named with an explicit template argument list. In this case, the "resolution" doesn't take into account the target type at all, and therefore can take place for functions, static member functions, and *non-static* member functions. The latter weren't being properly checked and their proper form enforced in this scenario. We now do so. The result of this last form slipping through was some confusing logic in IsStandardConversion handling of these resolved address-of expressions which eventually exploded in an assert. Simplify this logic a bit and add some more aggressive asserts to catch improperly formed expressions getting into this routine. Finally add systematic testing of member functions, both static and non-static, in the various forms they can take. One of these is essentially PR9563, and this commit fixes the crash in that PR. However, the diagnostics for this are still pretty terrible. We at least are now accepting the correct constructs and rejecting the invalid ones rather than accepting invalid or crashing as before. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@128456 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
353ee246e754e38db9b738240d18f1ecf2bb389b |
07-Mar-2011 |
Douglas Gregor <dgregor@apple.com> |
Produce a diagnostic for unused overloaded expressions, from Faisal Vali! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127148 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
|
1be8eec3ddd2a23c19b453c2639226174eb5d4a8 |
19-Feb-2011 |
Douglas Gregor <dgregor@apple.com> |
Handle the resolution of a reference to a function template (which includes explicitly-specified template arguments) to a function template specialization in cases where no deduction is performed or deduction fails. Patch by Faisal Vali, fixes PR7505! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126048 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2-resolve-single-template-id.cpp
ver.over/p2.cpp
ver.over/p4.cpp
|
b145ee6cc7d7db42ca4351ff3fe91f04e86a2f67 |
26-Jan-2011 |
Douglas Gregor <dgregor@apple.com> |
Implement the restriction that a function with a ref-qualifier cannot overload a function without a ref-qualifier (C++0x [over.load]p2). This, apparently, completes the implementation of rvalue references for *this. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124321 91177308-0d34-0410-b5e6-96231b3b80d8
ver.load/p2-0x.cpp
|
fcab48b626b7ce43625958e857061d721a43a5bc |
26-Jan-2011 |
Douglas Gregor <dgregor@apple.com> |
Rvalue references for *this: explicitly keep track of whether a reference binding is for the implicit object parameter of a member function with a ref-qualifier. My previous comment, that we didn't need to track this explicitly, was wrong: we do in fact get rvalue-references-prefer-rvalues overloading with ref-qualifiers. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124313 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.funcs/p4-0x.cpp
|
2c9a03f3b249e4d9d76eadf758a33142adc4d0a4 |
26-Jan-2011 |
Douglas Gregor <dgregor@apple.com> |
Rvalue references for *this: implement the implicit conversion rules for the implicit object argument to a non-static member function with a ref-qualifier (C++0x [over.match.funcs]p4). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124311 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.funcs/p4-0x.cpp
|
57c9f4f278fe15dc4964f2999486ffdbabce635c |
26-Jan-2011 |
Douglas Gregor <dgregor@apple.com> |
Rvalue references for *this: allow functions to be overloaded based on the presence and form of a ref-qualifier. Note that we do *not* yet implement the restriction in C++0x [over.load]p2 that requires either all non-static functions with a given parameter-type-list to have a ref-qualifier or none of them to have a ref-qualifier. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124297 91177308-0d34-0410-b5e6-96231b3b80d8
ver.load/p2-0x.cpp
|
440a48318c53647d6416bcb1ff1af1452aa5d453 |
26-Jan-2011 |
Douglas Gregor <dgregor@apple.com> |
Reinstate r124236 (tweaking the rvalue-reference overload resolution rules), now that we've actually have a clean build for me to sully. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124290 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.best/over.ics.rank/p3-0x.cpp
|
4d4feead7e240bf24264658b5abb0b88d52ed684 |
26-Jan-2011 |
Douglas Gregor <dgregor@apple.com> |
Speculatively revert r124236 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124247 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.best/over.ics.rank/p3-0x.cpp
|
b7cd135215501a154eb4f68159f3af020783099e |
25-Jan-2011 |
Douglas Gregor <dgregor@apple.com> |
Speculatively implement a tweak to the C++0x overload resolution rules for reference binding (C++ [over.rank.ics]p3b1sb4), so that we prefer the binding of an lvalue reference to a function lvalue over the binding of an rvalue reference. This change resolves the ambiguity with std::forward and lvalue references to function types in a way that seems consistent with the original rvalue references proposal. My proposed wording for this change is shown in isBetterReferenceBindingKind(); we'll try to get this change adopted in the C++0x working paper as well. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124236 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.best/over.ics.rank/p3-0x.cpp
|
48a4ce7d484a448490edfe9e1d47b806cee85f30 |
25-Jan-2011 |
Douglas Gregor <dgregor@apple.com> |
Fix the ranking of reference bindings during overload resolution (C++0x [over.ics.rank]p3) when one binding is an lvalue reference and the other is an rvalue reference that binds to an rvalue. In particular, we were using the predict "is an rvalue reference" rather than "is an rvalue reference that binds to an rvalue", which was incorrect in the one case where an rvalue reference can bind to an lvalue: function references. This particular issue cropped up with std::forward, where Clang was picking an std::forward overload while forwarding an (lvalue) reference to a function. However (and unfortunately!), the right answer for this code is that the call to std::forward is ambiguous. Clang now gets that right, but we need to revisit the std::forward implementation in libc++. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124216 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.best/over.ics.rank/p3-0x.cpp
|
b13ede9f440f52ccfce046f1eba98679e9ffc0e6 |
21-Jan-2011 |
Douglas Gregor <dgregor@apple.com> |
Add test for overload resolution's preference for binding an rvalue reference to an rvalue rather than binding a const-qualified lvalue reference to that rvalue. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123979 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.best/over.ics.rank/p3-0x.cpp
|
8d706ecf488c4f548c4f8cf0aa08ea82a4d6a5ba |
15-Nov-2010 |
Douglas Gregor <dgregor@apple.com> |
Implement C++0x [temp.func.order]p3 (aka DR532) properly. In particular, we only add the implement object parameter type if only one of the function templates is a non-static member function template. Moreover, since this DR differs from existing practice in C++98/03, this commit implements the existing practice (which ignores the first parameter of the function template that is not the non-static member function template) in C++98/03 mode. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@119145 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.funcs/p4.cpp
|
77bc572138543ef97ebec137522b763d6a6ee909 |
13-Nov-2010 |
Douglas Gregor <dgregor@apple.com> |
Implement C++ [over.match.funcs]p4 as it concerns partial ordering of function templates. Fixes PR8130. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@118944 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.funcs/p4.cpp
|
8e960435696b4ccf6a8ad0ed0530e3280b77af8b |
08-Nov-2010 |
Douglas Gregor <dgregor@apple.com> |
Properly diagnose invalid casts to function references. Patch by Faisal Vali, tweaked by me. Fixes PR8230. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@118400 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2.cpp
ver.over/p4.cpp
|
5a1f97ee183d2614db58452a4380dd11cb309263 |
15-Oct-2010 |
Douglas Gregor <dgregor@apple.com> |
Add builtin conditional operator candidates for scoped enumeration types, from Alp Toker! Fixes PR8344. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116549 91177308-0d34-0410-b5e6-96231b3b80d8
ver.built/p25.cpp
|
661b4939ae3f84380dc3e670a06e963b4b9d3b6e |
12-Sep-2010 |
Douglas Gregor <dgregor@apple.com> |
Implement the "note" in C++ [over.built]p1, which is actually meant to be a semantic requirement that a built-in overloaded operator is not added to the overload set of there is already a user-defined overloaded operator with the same parameter types. Fixes PR8087. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@113713 91177308-0d34-0410-b5e6-96231b3b80d8
ver.built/p1.cpp
|
c520c84f7e9c2d8d4a66ac438e10d815daaeae64 |
13-Apr-2010 |
Douglas Gregor <dgregor@apple.com> |
Implement C++ [over.ics.user]p3, which restricts the final conversion from a conversion function template specialization to one of exact match rank. We only know how to test this in C++0x with default function template arguments, but it's also in the C++03 spec. Fixes PR6285. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@101089 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.best/over.best.ics/over.ics.user/p3-0x.cpp
|
cfdc81a83467973b14e4ea5e9e9af1690f135415 |
19-Dec-2009 |
Eli Friedman <eli.friedman@gmail.com> |
Initialization improvements: addition of string initialization and a few small bug fixes in SemaInit, switch over SemaDecl to use it more often, and change a bunch of diagnostics which are different with the new initialization code. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91767 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2.cpp
ver.over/p4.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
ver.match/over.match.best/p1.cpp
ver.over/p1.cpp
ver.over/p2.cpp
ver.over/p4.cpp
|
bc0a2226c7fcd18b29b6846049e2cfcb872d3593 |
27-Jul-2009 |
Owen Anderson <resistor@mac.com> |
Update for LLVM API change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@77249 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2.cpp
|
5dfb823b43637d172e91a778e91d23a510af670b |
11-Jul-2009 |
Daniel Dunbar <daniel@zuster.org> |
Fix test case to match intent. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@75381 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p1.cpp
|
0d5dc8e23133d0b8d8d8e6d81834f4d11923dc82 |
09-Jul-2009 |
Douglas Gregor <dgregor@apple.com> |
Another little test for C++ [over.over] git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@75151 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p2.cpp
|
72e771f12a97700e578b28f953622a6b6916bef1 |
09-Jul-2009 |
Douglas Gregor <dgregor@apple.com> |
Add test for C++ [over.over.]p1, the contexts in which one can take the address of an overloaded function. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@75146 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p1.cpp
|
00aeb52314ec0b1902bb15aef9c62259296fbc29 |
09-Jul-2009 |
Douglas Gregor <dgregor@apple.com> |
Implement the simple form of overload resolution used when taking the address of an overloaded function (which may involve both functions and function templates). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@75069 91177308-0d34-0410-b5e6-96231b3b80d8
ver.over/p4.cpp
|
3e15cc318e9cd577eda56c0294f32535738d8630 |
08-Jul-2009 |
Douglas Gregor <dgregor@apple.com> |
Overload resolution prefers non-templates to templates git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@74971 91177308-0d34-0410-b5e6-96231b3b80d8
ver.match/over.match.best/p1.cpp
|