mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-09 20:12:21 +02:00
Made implicit tuple cast check names, fixed explicit tuple cast
This commit is contained in:
parent
1f77412536
commit
fd64aa64d9
12 changed files with 92 additions and 87 deletions
|
@ -1018,7 +1018,7 @@ void BfModule::TryInitVar(BfAstNode* checkNode, BfLocalVariable* localVar, BfTyp
|
|||
BfTypeInstance* srcTypeInstance = initValue.mType->ToTypeInstance();
|
||||
BfTypeInstance* varTypeInstance = varType->ToTypeInstance();
|
||||
|
||||
if (CanImplicitlyCast(initValue, varType))
|
||||
if (CanCast(initValue, varType))
|
||||
{
|
||||
if ((!varType->IsPointer()) && (!varType->IsObjectOrInterface()))
|
||||
{
|
||||
|
@ -1044,7 +1044,7 @@ void BfModule::TryInitVar(BfAstNode* checkNode, BfLocalVariable* localVar, BfTyp
|
|||
// // Class downcast
|
||||
// isDynamicCast = true;
|
||||
// }
|
||||
// else if ((!CanImplicitlyCast(GetFakeTypedValue(varType), initType)) && (!initType->IsGenericParam()))
|
||||
// else if ((!CanCast(GetFakeTypedValue(varType), initType)) && (!initType->IsGenericParam()))
|
||||
// {
|
||||
// if (!IsInSpecializedSection())
|
||||
// {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue