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
Save this to a file:
function line_offby1(v::Vector) if length(v) > 30 error("Too large!") end print(v[1]) print(v[31]) end function line_offby2(v::Vector) if length(v) > 30 error("Too large!") end print(v[1]) for i = 1:20 print(v[31]) end end
Then load the file and try this:
v = randn(5) line_offby1(v) line_offby2(v)
The offby2 one is off by 2 not because it comes second in the file (it's not cumulative across functions), but because of the for loop.
The text was updated successfully, but these errors were encountered:
Can we have a test for this in test/?
Sorry, something went wrong.
Dup of #922.
No branches or pull requests
Save this to a file:
Then load the file and try this:
The offby2 one is off by 2 not because it comes second in the file (it's not cumulative across functions), but because of the for loop.
The text was updated successfully, but these errors were encountered: