We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
If a variable is annotated with a tuple type, Retic does not dynamically check the contents of the tuple at dereferences.
A program:
def f(x:(Int,Int))->String: return x[0] + x[1]
retic -p
def f(x): check_type_tuple(x, 2) return check_type_string((x[0] + x[1])) f = check_type_function(f)
Sure tuples are immutable, but:
Example 1
def f(x:(Int,Int))->String: return x[0] + x[1] # Not sure why this type checks def main(x)->String: return f(x) main(("A", "B"))
Example 2
def g(x:(List(Int),Int))->(List(Int), Int): x[0][0] = "yolo" return x print(g(([0], 0))) # (["yolo", 0])
The text was updated successfully, but these errors were encountered:
No branches or pull requests
If a variable is annotated with a tuple type, Retic does not dynamically check the contents of the tuple at dereferences.
A program:
retic -p
Sure tuples are immutable, but:
Example 1
Example 2
The text was updated successfully, but these errors were encountered: