-
Notifications
You must be signed in to change notification settings - Fork 1.4k
[cling] Emit proper diagnostics in DynamicLookup for AutoType
#18170
New issue
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
Conversation
Test Results 20 files 20 suites 3d 12h 26m 33s ⏱️ For more details on these failures, see this check. Results for commit 9e986fa. ♻️ This comment has been updated with latest results. |
CC: @silverweed |
0d799ee
to
45fb5c9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lgtm, if we add a test in clingtest.
45fb5c9
to
daccf0a
Compare
daccf0a
to
9292714
Compare
@devajithvs do you think we can follow @hahnjo suggestion to move on, merge and close the associated issue? |
Done! The test is indeed very brittle and can break based on where // expected-error goes. eg,
will fail. |
Replace AST dumps with proper error messages in dynamic lookup when dealing with `auto`, which is unsupported for lookup Changes this: ``` root [0] auto var = someexpr(); ROOT_prompt_0:1:1: error: Syntax error auto var = someexpr(); ^ FunctionDecl 0x60cb530887f0 <input_line_8:1:1, ROOT_prompt_0:3:1> input_line_8:1:6 __cling_Un1Qu30 'void (void *)' |-ParmVarDecl 0x60cb53088738 <col:22, col:28> col:28 vpClingValue 'void *' |-CompoundStmt 0x60cb53088c30 <col:42, ROOT_prompt_0:3:1> | |-DeclStmt 0x60cb53088c10 <line:1:1, col:22> | | `-VarDecl 0x60cb53088910 <col:1, col:21> col:6 var 'auto' cinit | | `-CallExpr 0x60cb53088bc0 <col:12, col:21> '<dependent type>' | | `-DeclRefExpr 0x60cb53088b80 <col:12> '<dependent type>' lvalue Var 0x60cb53088aa8 'someexpr' '<dependent type>' | `-NullStmt 0x60cb53088c28 <line:2:1> |-AnnotateAttr 0x60cb53088a00 <<invalid sloc>> Implicit R"ATTRDUMP(__ResolveAtRuntime)ATTRDUMP" `-AnnotateAttr 0x60cb53088b10 <<invalid sloc>> Implicit R"ATTRDUMP(__ResolveAtRuntime)ATTRDUMP" <<<NULL>>> ``` to ``` root [0] auto var = someexpr(); ROOT_prompt_0:1:12: error: Cannot deduce 'auto' from unknown expression auto var = someexpr(); ^ ```
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks. The errors on mac14 seem unrelated.
Replace AST dumps with proper error messages in dynamic lookup when dealing with
auto
, which is unsupported for lookupChanges this:
to
This Pull request:
Changes or fixes:
Checklist:
Fixes #9261
CC: @guitargeek