Lines Matching full:conversions

110                         OverloadCandidateSet& Conversions,
259 /// implicit conversions.
279 // array-to-pointer or function-to-pointer implicit conversions, so
359 /// \param IgnoreFloatToIntegralConversion If true type-narrowing conversions
515 // Such conversions on variables are always narrowing.
573 // Other kinds of conversions are not narrowings.
613 OS << "No conversions required";
665 new (&conversions()) ConversionSet();
669 conversions().~ConversionSet();
676 new (&conversions()) ConversionSet(O.conversions());
1085 for (auto &C : i->Conversions)
1604 OverloadCandidateSet Conversions(From->getExprLoc(),
1607 Conversions, AllowExplicit,
1647 for (OverloadCandidateSet::iterator Cand = Conversions.begin();
1648 Cand != Conversions.end(); ++Cand)
1681 /// If @p SuppressUserConversions, then user-defined conversions are
1683 /// If @p AllowExplicit, then explicit user-defined conversions are
1902 // FIXME: disable conversions between long double, __ibm128 and __float128
1906 // Conversions between bfloat16 and float16 are currently not supported.
1913 // Conversions between IEEE-quad and IBM-extended semantics are not
1981 // Identical types require no conversions.
1985 // There are no conversions between extended vector types, only identity.
2005 // There are no conversions between extended vector types other than the
2040 // 2)lax vector conversions are permitted and the vector types are of the
2073 /// only consider non-class types; for conversions that involve class
2085 // Standard conversions (C++ [conv])
2091 // There are no standard conversions for class types in C++, so
2218 // We don't require any conversions for the first step.
2253 // Boolean conversions (C++ 4.12).
2258 // Integral conversions (C++ 4.7).
2262 // Complex conversions (C99 6.3.1.6)
2267 // Complex-real conversions (C99 6.3.1.7)
2271 // Floating point conversions (C++ 4.8).
2279 // Floating-integral conversions (C++ 4.9).
2289 // Pointer conversions (C++ 4.10).
2295 // Pointer to member conversions (4.11).
2304 // Compatible conversions (Clang extension for C function overloading)
2346 // Function pointer conversions (removing 'noexcept') including removal of
2675 /// Conversions to 'id' subsume cv-qualifier conversions.
2880 // First, we handle all conversions on ObjC object pointer types.
2978 // pointer conversions. If so, we permit the conversion (but
3059 // pointer conversions. If so, we permit the conversion.
3366 // Objective-C++ conversions are always okay.
3367 // FIXME: We should have a different class of conversions for the
3368 // Objective-C++ implicit conversions.
3514 // Check Objective-C lifetime conversions.
3522 // Qualification conversions cannot cast between different
3543 // conversions between overlapping address spaces.
3689 // Initializer lists don't have conversions as such.
3831 const auto &Conversions = FromRecordDecl->getVisibleConversionFunctions();
3832 for (auto I = Conversions.begin(), E = Conversions.end(); I != E; ++I) {
3876 // Initializer lists don't have conversions as such.
3879 if (Best->Conversions[0].isEllipsis())
3882 User.Before = Best->Conversions[0].Standard;
3902 User.Before = Best->Conversions[0].Standard;
3994 // If both conversion functions are implicitly-declared conversions from
4011 // defining ALL of the possible conversions in regards to calling-convention.
4359 // their derived-to-base conversions.
4365 // Both conversion sequences are conversions to void
4412 // Compare based on qualification conversions (C++ 13.3.3.2p3,
4532 /// qualification conversions (C++ 13.3.3.2p3 bullet 3).
4572 // Prefer qualification conversions not involving a change in lifetime
4573 // to qualification conversions that do change lifetime.
4585 // FIXME: In Objective-C ARC, we can have qualification conversions in both
4599 /// various kinds of derived-to-base conversions (C++
4601 /// conversions between Objective-C interface types.
4629 // Compare based on pointer conversions.
4632 /*FIXME: Remove if Objective-C id conversions get their own rank*/
4842 // Check for standard conversions we can apply to pointers: derived-to-base
4843 // conversions, ObjC pointer conversions, and function pointer conversions.
4844 // (Qualification conversions are checked last.)
4916 assert(T2->isRecordType() && "Can only find conversions of record types.");
4921 const auto &Conversions = T2RecordDecl->getVisibleConversionFunctions();
4922 for (auto I = Conversions.begin(), E = Conversions.end(); I != E; ++I) {
4997 ICS.UserDefined.Before = Best->Conversions[0].Standard;
5115 // derived-to-base conversions is suppressed when we're
5225 // related, and we aren't allowed any user conversions, the
5727 // are not allowed to perform user-defined conversions
5920 // conversion to bool in which explicit conversions are permitted.
5923 AllowedExplicit::Conversions,
5951 // conversions are fine.
5955 case ICK_Integral_Conversion: // Narrowing conversions are checked elsewhere.
5972 // C++1z: null pointer conversions and null member pointer conversions are
6034 // sequence contains only [... list of conversions ...].
6067 // Check that we would only use permitted conversions.
6268 /// involves any pointer conversions, remove them. This may change
6289 AllowedExplicit::Conversions,
6295 // Strip off any final conversions to 'id'.
6568 // We can only perform contextual implicit conversions on objects of class
6598 const auto &Conversions =
6602 (std::distance(Conversions.begin(), Conversions.end()) > 1);
6608 // Collect explicit or viable (potentially in C++1y) conversions.
6609 for (auto I = Conversions.begin(), E = Conversions.end(); I != E; ++I) {
6672 // potentially viable conversions.
7000 if (Candidate.Conversions[ConvIdx].isInitialized()) {
7009 Candidate.Conversions[ConvIdx] = TryCopyInitialization(
7014 if (Candidate.Conversions[ConvIdx].isBad()) {
7023 Candidate.Conversions[ConvIdx].setEllipsis();
7084 // incompatible pointer conversions to be a failure here.
7483 Candidate.Conversions[FirstConvIdx].setStaticObjectArgument();
7487 Candidate.Conversions[FirstConvIdx] = TryObjectArgumentInitialization(
7490 if (Candidate.Conversions[FirstConvIdx].isBad()) {
7522 if (Candidate.Conversions[ConvIdx].isInitialized()) {
7538 Candidate.Conversions[ConvIdx]
7544 if (Candidate.Conversions[ConvIdx].isBad()) {
7553 Candidate.Conversions[ConvIdx].setEllipsis();
7592 ConversionSequenceList Conversions;
7599 MethodTmpl, ParamTypes, Args, CandidateSet, Conversions,
7605 CandidateSet.addCandidate(Conversions.size(), Conversions);
7634 Conversions, PO);
7676 ConversionSequenceList Conversions;
7684 FunctionTemplate, ParamTypes, Args, CandidateSet, Conversions,
7689 CandidateSet.addCandidate(Conversions.size(), Conversions);
7719 /*AllowExplicitConversions=*/false, IsADLCandidate, Conversions, PO,
7726 ConversionSequenceList &Conversions, bool SuppressUserConversions,
7729 // FIXME: The cases in which we allow explicit conversions for constructor
7739 Conversions =
7754 Conversions[ConvIdx] = TryObjectArgumentInitialization(
7759 if (Conversions[ConvIdx].isBad())
7784 Conversions[ConvIdx]
7791 if (Conversions[ConvIdx].isBad())
7820 // Allow qualification conversions.
7826 // If we're not allowed to consider Objective-C pointer conversions,
7914 Candidate.Conversions[0] = TryObjectArgumentInitialization(
7920 if (Candidate.Conversions[0].isBad()) {
7937 // derived to base as such conversions are given Conversion Rank. They only
8130 Candidate.Conversions[0] = ObjectInit;
8137 Candidate.Conversions[0].setUserDefined();
8138 Candidate.Conversions[0].UserDefined.Before = ObjectInit.Standard;
8139 Candidate.Conversions[0].UserDefined.EllipsisConversion = false;
8140 Candidate.Conversions[0].UserDefined.HadMultipleCandidates = false;
8141 Candidate.Conversions[0].UserDefined.ConversionFunction = Conversion;
8142 Candidate.Conversions[0].UserDefined.FoundConversionFunction = FoundDecl;
8143 Candidate.Conversions[0].UserDefined.After
8144 = Candidate.Conversions[0].UserDefined.Before;
8145 Candidate.Conversions[0].UserDefined.After.setAsIdentityConversion();
8177 Candidate.Conversions[ArgIdx + 1]
8183 if (Candidate.Conversions[ArgIdx + 1].isBad()) {
8192 Candidate.Conversions[ArgIdx + 1].setEllipsis();
8324 // For the built-in assignment operators, conversions of the
8327 // -- no user-defined conversions are applied to the left
8331 // We block these conversions by turning off user-defined
8332 // conversions, since that is the only way that initialization of
8338 Candidate.Conversions[ArgIdx]
8341 Candidate.Conversions[ArgIdx]
8348 if (Candidate.Conversions[ArgIdx].isBad()) {
8576 // expression for the purposes of conversions.
8888 // add volatile version only if there are conversions to a volatile type.
8896 // Add restrict version only if there are conversions to a restrict type
9266 // where LR is the result of the usual arithmetic conversions
9276 // where LR is the result of the usual arithmetic conversions
9370 // where LR is the result of the usual arithmetic conversions
9683 // Add volatile/restrict version only if there are conversions to a
10322 // We don't allow incompatible pointer conversions in C++.
10333 // Define functions that don't require ill-formed conversions for a given
10335 unsigned NumArgs = Cand1.Conversions.size();
10336 assert(Cand2.Conversions.size() == NumArgs && "Overload candidate mismatch");
10339 bool Cand1Bad = IsIllFormedConversion(Cand1.Conversions[ArgIdx]);
10340 bool Cand2Bad = IsIllFormedConversion(Cand2.Conversions[ArgIdx]);
10358 Cand1.Conversions[ArgIdx],
10359 Cand2.Conversions[ArgIdx])) {
11122 const ImplicitConversionSequence &Conv = Cand->Conversions[I];
11281 // Diagnose base -> derived pointer conversions.
11928 // Except for failed conversions, the notes are identical for each candidate,
12005 for (unsigned N = Cand->Conversions.size(); I != N; ++I)
12006 if (Cand->Conversions[I].isInitialized() && Cand->Conversions[I].isBad())
12111 assert(Cand->Conversions.size() <= 2 && "builtin operator is not binary");
12116 if (Cand->Conversions.size() == 1) {
12129 for (const ImplicitConversionSequence &ICS : Cand->Conversions) {
12260 // 2. Bad conversions come first and are ordered by the number
12261 // of bad conversions and quality of good conversions.
12276 // If there's any ordering between the defined conversions...
12339 // Returns -1 if conversions in L are considered better.
12341 // 1 if conversions in R are better.
12347 assert(L.Conversions.size() == R.Conversions.size());
12348 for (unsigned I = 0, N = L.Conversions.size(); I != N; ++I) {
12351 : ConversionSignals::ForSequence(L.Conversions[I]);
12354 : ConversionSignals::ForSequence(R.Conversions[I]);
12386 unsigned ConvCount = Cand->Conversions.size();
12390 if (Cand->Conversions[ConvIdx].isInitialized() &&
12391 Cand->Conversions[ConvIdx].isBad()) {
12434 // Fill in the rest of the conversions.
12439 if (Cand->Conversions[ConvIdx].isInitialized()) {
12443 Cand->Conversions[ConvIdx].setAsIdentityConversion(
12446 Cand->Conversions[ConvIdx] =
12453 if (!Unfixable && Cand->Conversions[ConvIdx].isBad())
12457 Cand->Conversions[ConvIdx].setEllipsis();
12578 // FIXME: It's quite possible for different conversions to see
14307 Input, Best->BuiltinParamTypes[0], Best->Conversions[0], AA_Passing,
14487 // Always do placeholder-like conversions on the RHS.
14567 *this, OpLoc, Cand.Conversions[ArgIdx],
14568 Best->Conversions[ArgIdx]) ==
14768 Args[0], Best->BuiltinParamTypes[0], Best->Conversions[0],
14775 Args[1], Best->BuiltinParamTypes[1], Best->Conversions[1],
15146 Args[0], Best->BuiltinParamTypes[0], Best->Conversions[0],
15153 Args[1], Best->BuiltinParamTypes[1], Best->Conversions[1],
15612 const auto &Conversions =
15614 for (auto I = Conversions.begin(), E = Conversions.end();
15702 Best->Conversions[0].UserDefined.ConversionFunction);