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
The conversion of x to Test is represented as a Call and must be handle specially as Test is not a function name but rather an interface. Instead, there should be a type conversion node that converts x to type Test. Additionally, the Hex literal 0x0000000000000000000000000000000000000000 should have have a type conversion to address as it could also be bytes20. Representing these semantics explicitly will increase the accuracy of tools that attempt to model Vyper's semantics faithfully.
interface Test:
def foo() -> (int128, uint256): nonpayable
@internaldef foo() -> (int128, int128):
return2, 3@externaldef bar():
a: int128=0
b: int128=0
(a, b) =self.foo()
x: address=0x0000000000000000000000000000000000000000
c: uint256=0
a, c =Test(x).foo()
How can it be fixed?
Create explicit type conversion nodes in the AST
The text was updated successfully, but these errors were encountered:
Version Information
vyper --version
): 0.3.7python --version
): 3.11What's your issue about?
The conversion of
x
toTest
is represented as aCall
and must be handle specially asTest
is not a function name but rather an interface. Instead, there should be a type conversion node that convertsx
to typeTest
. Additionally, the Hex literal0x0000000000000000000000000000000000000000
should have have a type conversion toaddress
as it could also bebytes20
. Representing these semantics explicitly will increase the accuracy of tools that attempt to model Vyper's semantics faithfully.How can it be fixed?
Create explicit type conversion nodes in the AST
The text was updated successfully, but these errors were encountered: