Lines Matching refs:ICS

1184   ImplicitConversionSequence ICS;  in TryUserDefinedConversion()  local
1189 ICS.setBad(BadConversionSequence::no_conversion, From, ToType); in TryUserDefinedConversion()
1190 return ICS; in TryUserDefinedConversion()
1196 switch (IsUserDefinedConversion(S, From, ToType, ICS.UserDefined, in TryUserDefinedConversion()
1201 ICS.setUserDefined(); in TryUserDefinedConversion()
1202 ICS.UserDefined.Before.setAsIdentityConversion(); in TryUserDefinedConversion()
1211 = dyn_cast<CXXConstructorDecl>(ICS.UserDefined.ConversionFunction)) { in TryUserDefinedConversion()
1221 DeclAccessPair Found = ICS.UserDefined.FoundConversionFunction; in TryUserDefinedConversion()
1222 ICS.setStandard(); in TryUserDefinedConversion()
1223 ICS.Standard.setAsIdentityConversion(); in TryUserDefinedConversion()
1224 ICS.Standard.setFromType(From->getType()); in TryUserDefinedConversion()
1225 ICS.Standard.setAllToTypes(ToType); in TryUserDefinedConversion()
1226 ICS.Standard.CopyConstructor = Constructor; in TryUserDefinedConversion()
1227 ICS.Standard.FoundCopyConstructor = Found; in TryUserDefinedConversion()
1229 ICS.Standard.Second = ICK_Derived_To_Base; in TryUserDefinedConversion()
1235 ICS.setAmbiguous(); in TryUserDefinedConversion()
1236 ICS.Ambiguous.setFromType(From->getType()); in TryUserDefinedConversion()
1237 ICS.Ambiguous.setToType(ToType); in TryUserDefinedConversion()
1241 ICS.Ambiguous.addConversion(Cand->FoundDecl, Cand->Function); in TryUserDefinedConversion()
1246 ICS.setBad(BadConversionSequence::no_conversion, From, ToType); in TryUserDefinedConversion()
1250 return ICS; in TryUserDefinedConversion()
1288 ImplicitConversionSequence ICS; in TryImplicitConversion() local
1290 ICS.Standard, CStyle, AllowObjCWritebackConversion)){ in TryImplicitConversion()
1291 ICS.setStandard(); in TryImplicitConversion()
1292 return ICS; in TryImplicitConversion()
1296 ICS.setBad(BadConversionSequence::no_conversion, From, ToType); in TryImplicitConversion()
1297 return ICS; in TryImplicitConversion()
1311 ICS.setStandard(); in TryImplicitConversion()
1312 ICS.Standard.setAsIdentityConversion(); in TryImplicitConversion()
1313 ICS.Standard.setFromType(FromType); in TryImplicitConversion()
1314 ICS.Standard.setAllToTypes(ToType); in TryImplicitConversion()
1320 ICS.Standard.CopyConstructor = nullptr; in TryImplicitConversion()
1324 ICS.Standard.Second = ICK_Derived_To_Base; in TryImplicitConversion()
1326 return ICS; in TryImplicitConversion()
1357 ImplicitConversionSequence ICS; in PerformImplicitConversion() local
1358 return PerformImplicitConversion(From, ToType, Action, AllowExplicit, ICS); in PerformImplicitConversion()
1364 ImplicitConversionSequence& ICS) { in PerformImplicitConversion() argument
1375 ICS = ::TryImplicitConversion(*this, From, ToType, in PerformImplicitConversion()
1382 return PerformImplicitConversion(From, ToType, ICS, Action); in PerformImplicitConversion()
3328 ImplicitConversionSequence ICS; in DiagnoseMultipleUserDefinedConversion() local
3332 IsUserDefinedConversion(*this, From, ToType, ICS.UserDefined, in DiagnoseMultipleUserDefinedConversion()
3384 const ImplicitConversionSequence &ICS) { in hasDeprecatedStringLiteralToCharPtrConversion() argument
3385 return (ICS.isStandard() && ICS.Standard.DeprecatedStringLiteralToCharPtr) || in hasDeprecatedStringLiteralToCharPtrConversion()
3386 (ICS.isUserDefined() && in hasDeprecatedStringLiteralToCharPtrConversion()
3387 ICS.UserDefined.Before.DeprecatedStringLiteralToCharPtr); in hasDeprecatedStringLiteralToCharPtrConversion()
4160 FindConversionForRefInit(Sema &S, ImplicitConversionSequence &ICS, in FindConversionForRefInit() argument
4253 ICS.setUserDefined(); in FindConversionForRefInit()
4254 ICS.UserDefined.Before = Best->Conversions[0].Standard; in FindConversionForRefInit()
4255 ICS.UserDefined.After = Best->FinalConversion; in FindConversionForRefInit()
4256 ICS.UserDefined.HadMultipleCandidates = HadMultipleCandidates; in FindConversionForRefInit()
4257 ICS.UserDefined.ConversionFunction = Best->Function; in FindConversionForRefInit()
4258 ICS.UserDefined.FoundConversionFunction = Best->FoundDecl; in FindConversionForRefInit()
4259 ICS.UserDefined.EllipsisConversion = false; in FindConversionForRefInit()
4260 assert(ICS.UserDefined.After.ReferenceBinding && in FindConversionForRefInit()
4261 ICS.UserDefined.After.DirectBinding && in FindConversionForRefInit()
4266 ICS.setAmbiguous(); in FindConversionForRefInit()
4270 ICS.Ambiguous.addConversion(Cand->FoundDecl, Cand->Function); in FindConversionForRefInit()
4293 ImplicitConversionSequence ICS; in TryReferenceInit() local
4294 ICS.setBad(BadConversionSequence::no_conversion, Init, DeclType); in TryReferenceInit()
4339 ICS.setStandard(); in TryReferenceInit()
4340 ICS.Standard.First = ICK_Identity; in TryReferenceInit()
4341 ICS.Standard.Second = DerivedToBase? ICK_Derived_To_Base in TryReferenceInit()
4344 ICS.Standard.Third = ICK_Identity; in TryReferenceInit()
4345 ICS.Standard.FromTypePtr = T2.getAsOpaquePtr(); in TryReferenceInit()
4346 ICS.Standard.setToType(0, T2); in TryReferenceInit()
4347 ICS.Standard.setToType(1, T1); in TryReferenceInit()
4348 ICS.Standard.setToType(2, T1); in TryReferenceInit()
4349 ICS.Standard.ReferenceBinding = true; in TryReferenceInit()
4350 ICS.Standard.DirectBinding = true; in TryReferenceInit()
4351 ICS.Standard.IsLvalueReference = !isRValRef; in TryReferenceInit()
4352 ICS.Standard.BindsToFunctionLvalue = T2->isFunctionType(); in TryReferenceInit()
4353 ICS.Standard.BindsToRvalue = false; in TryReferenceInit()
4354 ICS.Standard.BindsImplicitObjectArgumentWithoutRefQualifier = false; in TryReferenceInit()
4355 ICS.Standard.ObjCLifetimeConversionBinding = ObjCLifetimeConversion; in TryReferenceInit()
4356 ICS.Standard.CopyConstructor = nullptr; in TryReferenceInit()
4357 ICS.Standard.DeprecatedStringLiteralToCharPtr = false; in TryReferenceInit()
4363 return ICS; in TryReferenceInit()
4376 if (FindConversionForRefInit(S, ICS, DeclType, DeclLoc, in TryReferenceInit()
4379 return ICS; in TryReferenceInit()
4387 return ICS; in TryReferenceInit()
4397 ICS.setStandard(); in TryReferenceInit()
4398 ICS.Standard.First = ICK_Identity; in TryReferenceInit()
4399 ICS.Standard.Second = DerivedToBase? ICK_Derived_To_Base in TryReferenceInit()
4402 ICS.Standard.Third = ICK_Identity; in TryReferenceInit()
4403 ICS.Standard.FromTypePtr = T2.getAsOpaquePtr(); in TryReferenceInit()
4404 ICS.Standard.setToType(0, T2); in TryReferenceInit()
4405 ICS.Standard.setToType(1, T1); in TryReferenceInit()
4406 ICS.Standard.setToType(2, T1); in TryReferenceInit()
4407 ICS.Standard.ReferenceBinding = true; in TryReferenceInit()
4413 ICS.Standard.DirectBinding = in TryReferenceInit()
4416 ICS.Standard.IsLvalueReference = !isRValRef; in TryReferenceInit()
4417 ICS.Standard.BindsToFunctionLvalue = T2->isFunctionType(); in TryReferenceInit()
4418 ICS.Standard.BindsToRvalue = InitCategory.isRValue(); in TryReferenceInit()
4419 ICS.Standard.BindsImplicitObjectArgumentWithoutRefQualifier = false; in TryReferenceInit()
4420 ICS.Standard.ObjCLifetimeConversionBinding = ObjCLifetimeConversion; in TryReferenceInit()
4421 ICS.Standard.CopyConstructor = nullptr; in TryReferenceInit()
4422 ICS.Standard.DeprecatedStringLiteralToCharPtr = false; in TryReferenceInit()
4423 return ICS; in TryReferenceInit()
4438 FindConversionForRefInit(S, ICS, DeclType, DeclLoc, in TryReferenceInit()
4445 if (ICS.isUserDefined() && isRValRef && in TryReferenceInit()
4446 ICS.UserDefined.After.First == ICK_Lvalue_To_Rvalue) in TryReferenceInit()
4447 ICS.setBad(BadConversionSequence::no_conversion, Init, DeclType); in TryReferenceInit()
4449 return ICS; in TryReferenceInit()
4454 return ICS; in TryReferenceInit()
4481 return ICS; in TryReferenceInit()
4491 return ICS; in TryReferenceInit()
4497 return ICS; in TryReferenceInit()
4509 ICS = TryImplicitConversion(S, Init, T1, SuppressUserConversions, in TryReferenceInit()
4517 if (ICS.isStandard()) { in TryReferenceInit()
4518 ICS.Standard.ReferenceBinding = true; in TryReferenceInit()
4519 ICS.Standard.IsLvalueReference = !isRValRef; in TryReferenceInit()
4520 ICS.Standard.BindsToFunctionLvalue = false; in TryReferenceInit()
4521 ICS.Standard.BindsToRvalue = true; in TryReferenceInit()
4522 ICS.Standard.BindsImplicitObjectArgumentWithoutRefQualifier = false; in TryReferenceInit()
4523 ICS.Standard.ObjCLifetimeConversionBinding = false; in TryReferenceInit()
4524 } else if (ICS.isUserDefined()) { in TryReferenceInit()
4526 ICS.UserDefined.ConversionFunction->getReturnType() in TryReferenceInit()
4539 ICS.setBad(BadConversionSequence::lvalue_ref_to_rvalue, Init, DeclType); in TryReferenceInit()
4540 return ICS; in TryReferenceInit()
4543 ICS.UserDefined.Before.setAsIdentityConversion(); in TryReferenceInit()
4544 ICS.UserDefined.After.ReferenceBinding = true; in TryReferenceInit()
4545 ICS.UserDefined.After.IsLvalueReference = !isRValRef; in TryReferenceInit()
4546 ICS.UserDefined.After.BindsToFunctionLvalue = false; in TryReferenceInit()
4547 ICS.UserDefined.After.BindsToRvalue = !LValRefType; in TryReferenceInit()
4548 ICS.UserDefined.After.BindsImplicitObjectArgumentWithoutRefQualifier = false; in TryReferenceInit()
4549 ICS.UserDefined.After.ObjCLifetimeConversionBinding = false; in TryReferenceInit()
4552 return ICS; in TryReferenceInit()
4641 ImplicitConversionSequence ICS = in TryListConversion() local
4646 if (ICS.isBad()) { in TryListConversion()
4647 Result = ICS; in TryListConversion()
4652 CompareImplicitConversionSequences(S, From->getLocStart(), ICS, in TryListConversion()
4655 Result = ICS; in TryListConversion()
4850 ImplicitConversionSequence ICS = in TryCopyInitialization() local
4853 return !ICS.isBad(); in TryCopyInitialization()
4873 ImplicitConversionSequence ICS; in TryObjectArgumentInitialization() local
4909 ICS.setBad(BadConversionSequence::bad_qualifiers, in TryObjectArgumentInitialization()
4911 return ICS; in TryObjectArgumentInitialization()
4923 ICS.setBad(BadConversionSequence::unrelated_class, in TryObjectArgumentInitialization()
4925 return ICS; in TryObjectArgumentInitialization()
4937 ICS.setBad(BadConversionSequence::lvalue_ref_to_rvalue, FromType, in TryObjectArgumentInitialization()
4939 return ICS; in TryObjectArgumentInitialization()
4946 ICS.setBad(BadConversionSequence::rvalue_ref_to_lvalue, FromType, in TryObjectArgumentInitialization()
4948 return ICS; in TryObjectArgumentInitialization()
4954 ICS.setStandard(); in TryObjectArgumentInitialization()
4955 ICS.Standard.setAsIdentityConversion(); in TryObjectArgumentInitialization()
4956 ICS.Standard.Second = SecondKind; in TryObjectArgumentInitialization()
4957 ICS.Standard.setFromType(FromType); in TryObjectArgumentInitialization()
4958 ICS.Standard.setAllToTypes(ImplicitParamType); in TryObjectArgumentInitialization()
4959 ICS.Standard.ReferenceBinding = true; in TryObjectArgumentInitialization()
4960 ICS.Standard.DirectBinding = true; in TryObjectArgumentInitialization()
4961 ICS.Standard.IsLvalueReference = Method->getRefQualifier() != RQ_RValue; in TryObjectArgumentInitialization()
4962 ICS.Standard.BindsToFunctionLvalue = false; in TryObjectArgumentInitialization()
4963 ICS.Standard.BindsToRvalue = FromClassification.isRValue(); in TryObjectArgumentInitialization()
4964 ICS.Standard.BindsImplicitObjectArgumentWithoutRefQualifier in TryObjectArgumentInitialization()
4966 return ICS; in TryObjectArgumentInitialization()
4994 ImplicitConversionSequence ICS = TryObjectArgumentInitialization( in PerformObjectArgumentInitialization() local
4997 if (ICS.isBad()) { in PerformObjectArgumentInitialization()
4998 if (ICS.Bad.Kind == BadConversionSequence::bad_qualifiers) { in PerformObjectArgumentInitialization()
5018 if (ICS.Standard.Second == ICK_Derived_To_Base) { in PerformObjectArgumentInitialization()
5051 ImplicitConversionSequence ICS = TryContextuallyConvertToBool(*this, From); in PerformContextuallyConvertToBool() local
5052 if (!ICS.isBad()) in PerformContextuallyConvertToBool()
5053 return PerformImplicitConversion(From, Context.BoolTy, ICS, AA_Converting); in PerformContextuallyConvertToBool()
5144 ImplicitConversionSequence ICS = in CheckConvertedConstantExpression() local
5151 switch (ICS.getKind()) { in CheckConvertedConstantExpression()
5153 SCS = &ICS.Standard; in CheckConvertedConstantExpression()
5158 SCS = &ICS.UserDefined.After; in CheckConvertedConstantExpression()
5186 S.PerformImplicitConversion(From, T, ICS, Sema::AA_Converting); in CheckConvertedConstantExpression()
5282 ImplicitConversionSequence ICS in TryContextuallyConvertToObjCPointer() local
5293 switch (ICS.getKind()) { in TryContextuallyConvertToObjCPointer()
5300 dropPointerConversion(ICS.UserDefined.After); in TryContextuallyConvertToObjCPointer()
5304 dropPointerConversion(ICS.Standard); in TryContextuallyConvertToObjCPointer()
5308 return ICS; in TryContextuallyConvertToObjCPointer()
5318 ImplicitConversionSequence ICS = in PerformContextuallyConvertToObjCPointer() local
5320 if (!ICS.isBad()) in PerformContextuallyConvertToObjCPointer()
5321 return PerformImplicitConversion(From, Ty, ICS, AA_Converting); in PerformContextuallyConvertToObjCPointer()
6496 ImplicitConversionSequence ICS = in AddConversionCandidate() local
6502 switch (ICS.getKind()) { in AddConversionCandidate()
6504 Candidate.FinalConversion = ICS.Standard; in AddConversionCandidate()
6511 GetConversionRank(ICS.Standard.Second) != ICR_Exact_Match) { in AddConversionCandidate()
6523 ICS.Standard.First == ICK_Lvalue_To_Rvalue) { in AddConversionCandidate()
9813 const ImplicitConversionSequence &ICS = Cand->Conversions[ArgIdx]; in NoteAmbiguousUserConversions() local
9814 if (ICS.isBad()) break; // all meaningless after first invalid in NoteAmbiguousUserConversions()
9815 if (!ICS.isAmbiguous()) continue; in NoteAmbiguousUserConversions()
9817 ICS.DiagnoseAmbiguousConversion( in NoteAmbiguousUserConversions()