Warn when function type passed to interpolated string#19289
Warn when function type passed to interpolated string#19289
Conversation
- Extract duplicated warning block into warnForFunctionValuesInFillExprs local function - Restore accidentally deleted withStdOutContains assertion in FormattableString test
❗ Release notes requiredCaution No release notes found for the changed paths (see table below). Please make sure to add an entry with an informative description of the change as well as link to this pull request, issue and language suggestion if applicable. Release notes for this repository are based on Keep A Changelog format. The following format is recommended for this repository:
If you believe that release notes are not necessary for this PR, please add NO_RELEASE_NOTES label to the pull request. You can open this PR in browser to add release notes: open in github.dev
|
| if argTys.Length <> synFillExprs.Length then | ||
| error (Error(FSComp.SR.tcInterpolationMixedWithPercent(), m)) | ||
|
|
||
| let warnForFunctionValuesInFillExprs () = |
There was a problem hiding this comment.
This can be a upper level inline function and not create a closure over tcglobals and others, but take them as parameters. Will result in proper inlining.
There was a problem hiding this comment.
There's a good chance this is automatically hoisted, so no closure
No description provided.