Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Merge features/interpolated-string into main#54692

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
333fred merged 53 commits intomainfromfeatures/interpolated-string
Jul 9, 2021
Merged
Show file tree
Hide file tree
Changes from1 commit
Commits
Show all changes
53 commits
Select commitHold shift + click to select a range
a2197d9
Merge pull request #51543 from dotnet/merges/master-to-features/inter…
Feb 28, 2021
58ee9c5
Merge pull request #51719 from dotnet/merges/main-to-features/interpo…
Mar 8, 2021
c94fa54
Merge pull request #51865 from dotnet/merges/main-to-features/interpo…
Mar 14, 2021
2b5d67b
Merge pull request #52026 from dotnet/merges/main-to-features/interpo…
Mar 22, 2021
fd2072d
Merge remote-tracking branch 'upstream/main' into merge-main
333fredMar 25, 2021
8623b91
Merge pull request #52156 from 333fred/merge-main
Mar 26, 2021
54d3c06
Merge pull request #52199 from dotnet/merges/main-to-features/interpo…
Mar 28, 2021
21fc275
Merge pull request #52403 from dotnet/merges/main-to-features/interpo…
Apr 4, 2021
b2afcc1
Merge pull request #52549 from dotnet/merges/main-to-features/interpo…
Apr 11, 2021
3efe70d
Merge pull request #52899 from dotnet/merges/main-to-features/interpo…
333fredApr 25, 2021
0a86282
Merge pull request #53083 from dotnet/merges/main-to-features/interpo…
May 4, 2021
8a59240
Implement binding and lowering for InterpolatedStringBuilder (#52422)
333fredMay 7, 2021
253c752
Merge remote-tracking branch 'upstream/main' into merges/main-to-feat…
333fredMay 10, 2021
38df25e
Merge pull request #53283 from dotnet/merges/main-to-features/interpo…
May 11, 2021
a4ebff3
Move from calling Create to calling a specific constructor (#53262)
333fredMay 12, 2021
a520ef8
Merge pull request #53443 from dotnet/merges/main-to-features/interpo…
333fredMay 17, 2021
77ec844
Merge remote-tracking branch 'upstream/main' into merges/main-to-feat…
333fredMay 24, 2021
ffee833
Merge pull request #53622 from dotnet/merges/main-to-features/interpo…
May 24, 2021
e7e6d24
Merge pull request #53774 from dotnet/merges/main-to-features/interpo…
May 30, 2021
66267da
Add support for interpolated string handler conversions (#53602)
333fredJun 1, 2021
5facc75
Merge pull request #53900 from dotnet/merges/main-to-features/interpo…
Jun 6, 2021
e0a2cd6
InterpolatedStringHandlerArgumentAttribute Decoding (#53932)
333fredJun 10, 2021
520d492
Merge remote-tracking branch 'upstream/main' into merges/main-to-feat…
333fredJun 14, 2021
192709e
Merge pull request #54063 from dotnet/merges/main-to-features/interpo…
Jun 17, 2021
e335d4d
Add support for InterpolatedStringBuilderArgumentAttribute
333fredJun 21, 2021
6f901de
PR feedback.
333fredJun 23, 2021
ad95c65
Address feedback in the local rewriter. Initial binding feedback is s…
333fredJun 25, 2021
af0b518
Initial binding feedback and additional tests.
333fredJun 25, 2021
3a9ed5a
Actually rewrite function pointer arguments, fix warning.
333fredJun 25, 2021
7c90a20
PR Feedback.
333fredJun 28, 2021
e0ac811
More PR feedback.
333fredJun 29, 2021
d57ccfe
Fix formatting.
333fredJun 29, 2021
1731e2a
Updated from feedback.
333fredJul 1, 2021
b3a354f
Merge pull request #54276 from 333fred/interpolated-string-arguments-…
333fredJul 2, 2021
562e159
Implement DefiniteAssignment support for interpolated strings
333fredJul 2, 2021
9ca7bdf
Add initial IOperation support for interpolated strings.
333fredJul 2, 2021
b39e57d
Adjust OperationTreeVerifier handling of quotes to not double-escape …
333fredJul 2, 2021
e008e8d
Add basic interpolated string nullable handling and tests.
333fredJul 3, 2021
1db9ee9
Remove some prototype comments.
333fredJul 3, 2021
f59c9e5
Support dynamic in AppendFormatted calls.
333fredJul 6, 2021
83395ca
Correctly handle ref-safe-to-escape.
333fredJul 7, 2021
e77a649
Correct ref-safe-to-escape lifetimes, fix bootstrap build.
333fredJul 7, 2021
73be92a
PR feedback.
333fredJul 7, 2021
2db9f36
More PR feedback.
333fredJul 7, 2021
ae6c341
Remove double spacing.
333fredJul 7, 2021
c5312b7
Prevent null refs for invalid scenarios.
333fredJul 7, 2021
ba890dd
Fix formatting and test.
333fredJul 7, 2021
7659bdc
More formatting.
333fredJul 8, 2021
93b9822
Merge pull request #54585 from 333fred/cleanup
333fredJul 8, 2021
2b1004b
Merge remote-tracking branch 'upstream/main' into merge-main
333fredJul 8, 2021
092b022
Condense error messages and update tests for CSharp 10.
333fredJul 8, 2021
cf9f752
Add missing warning to the non-nullable warnings list.
333fredJul 8, 2021
e7f4323
Merge pull request #54680 from 333fred/merge-main
333fredJul 8, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
PrevPrevious commit
NextNext commit
Address feedback in the local rewriter. Initial binding feedback is s…
…till mostly unaddressed.
  • Loading branch information
@333fred
333fred committedJun 25, 2021
commitad95c65f6cd5277c7ed1d15897770623db376b6d
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -634,7 +634,7 @@ private BoundExpression BindInterpolatedStringHandlerInMemberCall(
var parameter = GetCorrespondingParameter(ref memberAnalysisResult, parameters, originalParameterIndex);
if (parameter.IsOptional)
{
// Parameter '{0}' isoptional, but is used as an argument to the interpolated string handler conversion on parameter '{1}'. Specify the value of '{0}' before '{1}'.
// Parameter '{0}' isnot explicitly provided, but is used as an argument to the interpolated string handler conversion on parameter '{1}'. Specify the value of '{0}' before '{1}'.
diagnostics.Add(
ErrorCode.ERR_InterpolatedStringHandlerArgumentOptionalNotSpecified,
unconvertedString.Syntax.Location,
Expand All@@ -651,7 +651,7 @@ private BoundExpression BindInterpolatedStringHandlerInMemberCall(
var parameter = GetCorrespondingParameter(ref memberAnalysisResult, parameters, argumentIndex);
if (argumentIndex > interpolatedStringArgNum)
{
// Parameter '{0}' is an argument to the interpolated string handler conversion on parameter '{1}', but is specified after the interpolated stringconstant. Reorder the arguments to move '{0}' before '{1}'.
// Parameter '{0}' is an argument to the interpolated string handler conversion on parameter '{1}', butthe corresponding argumentis specified after the interpolated stringexpression. Reorder the arguments to move '{0}' before '{1}'.
diagnostics.Add(
ErrorCode.ERR_InterpolatedStringHandlerArgumentLocatedAfterInterpolatedString,
arguments[argumentIndex].Syntax.Location,
Expand Down
4 changes: 2 additions & 2 deletionssrc/Compilers/CSharp/Portable/Binder/Binder_Invocation.cs
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -2013,8 +2013,8 @@ private BoundFunctionPointerInvocation BindFunctionPointerInvocation(SyntaxNode
methodResult,
analyzedArguments.Arguments,
diagnostics,
boundExpression.Type,
boundExpression.GetRefKind());
receiverType: null,
receiverRefKind: default);

var args = analyzedArguments.Arguments.ToImmutable();
var refKinds = analyzedArguments.RefKinds.ToImmutableOrNull();
Expand Down
4 changes: 2 additions & 2 deletionssrc/Compilers/CSharp/Portable/CSharpResources.resx
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -6686,10 +6686,10 @@ To remove the warning, you can use /reference instead (set the Embed Interop Typ
<comment>InterpolatedStringHandlerArgumentAttribute is a type name and should not be translated.</comment>
</data>
<data name="ERR_InterpolatedStringHandlerArgumentLocatedAfterInterpolatedString" xml:space="preserve">
<value>Parameter '{0}' is an argument to the interpolated string handler conversion on parameter '{1}', but is specified after the interpolated stringconstant. Reorder the arguments to move '{0}' before '{1}'.</value>
<value>Parameter '{0}' is an argument to the interpolated string handler conversion on parameter '{1}', butthe corresponding argumentis specified after the interpolated stringexpression. Reorder the arguments to move '{0}' before '{1}'.</value>
</data>
<data name="ERR_InterpolatedStringHandlerArgumentOptionalNotSpecified" xml:space="preserve">
<value>Parameter '{0}' isoptional, but is used as an argument to the interpolated string handler conversion on parameter '{1}'. Specify the value of '{0}' before '{1}'.</value>
<value>Parameter '{0}' isnot explicitly provided, but is used as an argument to the interpolated string handler conversion on parameter '{1}'. Specify the value of '{0}' before '{1}'.</value>
</data>
<data name="ERR_ExpressionTreeContainsInterpolatedStringHandlerConversion" xml:space="preserve">
<value>An expression tree may not contain an interpolated string handler conversion.</value>
Expand Down
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -442,19 +442,6 @@ private void RemovePlaceholderReplacement(BoundValuePlaceholderBase placeholder)
Debug.Assert(removed);
}

private void RemovePlaceholderReplacementIfPresent(BoundValuePlaceholderBase placeholder)
{
Debug.Assert(placeholder is { });
Debug.Assert(_placeholderReplacementMapDoNotUseDirectly is { });
_ = _placeholderReplacementMapDoNotUseDirectly.Remove(placeholder);
}

private bool HasPlaceholderReplacement(BoundValuePlaceholderBase placeholder)
{
Debug.Assert(placeholder is not null);
return _placeholderReplacementMapDoNotUseDirectly?.ContainsKey(placeholder) ?? false;
}

public sealed override BoundNode VisitOutDeconstructVarPendingInference(OutDeconstructVarPendingInference node)
{
// OutDeconstructVarPendingInference nodes are only used within initial binding, but don't survive past that stage
Expand Down
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -2,11 +2,10 @@
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

using System;
using System.Collections.Immutable;
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis;
using Microsoft.CodeAnalysis.CSharp.Symbols;
using Microsoft.CodeAnalysis.PooledObjects;
using Roslyn.Utilities;

namespace Microsoft.CodeAnalysis.CSharp
Expand DownExpand Up@@ -312,19 +311,31 @@ private BoundExpression MakePropertyAssignment(
rewrittenRight);
}

ImmutableArray<LocalSymbol> argTemps;
arguments = VisitArguments(
syntax,
arguments,
property,
expanded,
argsToParamsOpt,
ref argumentRefKindsOpt,
out argTemps,
ref rewrittenReceiver,
out ArrayBuilder<LocalSymbol>? argTempsBuilder,
out BitVector positionsAssignedToTemp,
receiverIsArgumentSideEffectSequence: out _);

arguments = MakeArguments(
syntax,
arguments,
property,
expanded,
argsToParamsOpt,
ref argumentRefKindsOpt,
ref argTempsBuilder,
positionsAssignedToTemp,
invokedAsExtensionMethod: false,
enableCallerInfo: ThreeState.True);

var argTemps = argTempsBuilder?.ToImmutableAndFree() ?? default;

if (used)
{
// Save expression value to a temporary before calling the
Expand Down
Loading

[8]ページ先頭

©2009-2025 Movatter.jp