You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
localinterfaceI<L>_: LendlocalrecordAendlocalrecordIAisI<A>endlocalrecordBendlocalrecordIBisI<B>endlocalfunctionCreate<L, CisI<L>>(l: L, c:C): Creturn {}
endlocalfunctionTest(a: A, b: B)
-- Test 1Create(a, IA)
Create(b, IB) -- Error: argument 2: given type IB does not satisfy I<L> constraint in type variable CCreate(b, IA) -- No error, but it should.-- Test 2 -- No error if separate 2 function calls in different scope-- do-- Create(a, IA)-- end-- do-- Create(b, IB)-- end end
It seems after Create first gets called, all the following function calls in the same scope will use the same type resolve results.
Desired behavior: the teal compiler can resolve the type correctly.
The text was updated successfully, but these errors were encountered:
It seems after
Create
first gets called, all the following function calls in the same scope will use the same type resolve results.Desired behavior: the teal compiler can resolve the type correctly.
The text was updated successfully, but these errors were encountered: