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
I had a look at this issue and I was wondering how (and if) a single semicolon in a line is represented in the AST?
My first approach to solve this issue was passing the body block of the function to check_ret and check if the last statement is a single semicolon. (the code, which prints the number of statements in a block from check_ret can be found here: fhahn@4033420)
But it seems there is no statement for a single semicolon. Is it possible that a single semicolon gets dropped from the AST?
Activity
catamorphism commentedon Oct 15, 2013
I think this error message is confusing for beginners. Nominating.
catamorphism commentedon Oct 17, 2013
1.0, high
fhahn commentedon Oct 22, 2013
I had a look at this issue and I was wondering how (and if) a single semicolon in a line is represented in the AST?
My first approach to solve this issue was passing the body block of the function to
check_ret
and check if the last statement is a single semicolon. (the code, which prints the number of statements in a block fromcheck_ret
can be found here: fhahn@4033420)But it seems there is no statement for a single semicolon. Is it possible that a single semicolon gets dropped from the AST?
lambda-fairy commentedon Jan 10, 2014
@fhahn I found this definition in
libsyntax/ast.rs
:You might like to look at the
expr
field.auto merge of #11482 : fhahn/rust/issue-8005-better-error-msg-semi-la…