Skip to content

Don't use DefaultInterpolatedStringHandler in expression trees#55125

Merged
333fred merged 3 commits intodotnet:mainfrom
333fred:interpolation-expr-trees
Jul 27, 2021
Merged

Don't use DefaultInterpolatedStringHandler in expression trees#55125
333fred merged 3 commits intodotnet:mainfrom
333fred:interpolation-expr-trees

Conversation

@333fred
Copy link
Copy Markdown
Member

@333fred 333fred commented Jul 26, 2021

Introduces a binder flag to track whether we are currently in an expression tree or not. Fixes #55114.

@ghost ghost added the Area-Compilers label Jul 26, 2021
Introduces a binder flag to track whether we are currently in an expression tree or not. Fixes dotnet#55114.
@333fred 333fred force-pushed the interpolation-expr-trees branch from 9d0e52e to d29bc18 Compare July 26, 2021 22:09
@333fred 333fred marked this pull request as ready for review July 26, 2021 23:20
@333fred 333fred requested a review from a team as a code owner July 26, 2021 23:20
@333fred
Copy link
Copy Markdown
Member Author

333fred commented Jul 26, 2021

@dotnet/roslyn-compiler for review.

@jcouv jcouv self-assigned this Jul 27, 2021
Comment thread src/Compilers/CSharp/Test/Semantic/Semantics/InterpolationTests.cs Outdated
Comment thread src/Compilers/CSharp/Portable/Binder/Binder_Conversions.cs Outdated
Comment thread src/Compilers/CSharp/Test/Semantic/Semantics/InterpolationTests.cs
Copy link
Copy Markdown
Member

@jcouv jcouv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done with review pass (iteration 2)

Comment thread src/Compilers/CSharp/Portable/BoundTree/UnboundLambda.cs Outdated
@333fred
Copy link
Copy Markdown
Member Author

333fred commented Jul 27, 2021

@jcouv @chsienki addressed feedback, thanks. Please take another look.

IL_0087: pop
IL_0088: ret
}
");
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: I had a different kind of test in mind (less noisy), possibly using ExpressionTestLibrary, but I guess this works too. Sorry, I should have been specific.

Copy link
Copy Markdown
Member

@jcouv jcouv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM Thanks (iteration 3)

@333fred 333fred enabled auto-merge (squash) July 27, 2021 17:41
@333fred 333fred merged commit cfc12ce into dotnet:main Jul 27, 2021
@ghost ghost added this to the Next milestone Jul 27, 2021
@333fred 333fred deleted the interpolation-expr-trees branch July 27, 2021 20:03
@allisonchou allisonchou modified the milestones: Next, 17.0.P3 Jul 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Interpolated string in expression tree lambda doesn't compile

4 participants