We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
default as C
It's probably good to also test default as T where T is an open type.
default as T
T
at System.Diagnostics.Debug.Assert(Boolean condition) Binder\Binder_Operators.cs(3035,0): at Microsoft.CodeAnalysis.CSharp.Binder.BindAsOperator(BinaryExpressionSyntax node, DiagnosticBag diagnostics) Binder\Binder_Expressions.cs(510,0): at Microsoft.CodeAnalysis.CSharp.Binder.BindExpressionInternal(ExpressionSyntax node, DiagnosticBag diagnostics, Boolean invoked, Boolean indexed) Binder\Binder_Expressions.cs(414,0): at Microsoft.CodeAnalysis.CSharp.Binder.BindExpressionAllowArgList(ExpressionSyntax node, DiagnosticBag diagnostics) Binder\Binder_Expressions.cs(310,0): at Microsoft.CodeAnalysis.CSharp.Binder.BindValueAllowArgList(ExpressionSyntax node, DiagnosticBag diagnostics, BindValueKind valueKind) Binder\Binder_Expressions.cs(2202,0): at Microsoft.CodeAnalysis.CSharp.Binder.BindArgumentExpression(DiagnosticBag diagnostics, ExpressionSyntax argumentExpression, RefKind refKind, Boolean allowArglist) Binder\Binder_Expressions.cs(2048,0): at Microsoft.CodeAnalysis.CSharp.Binder.BindArgumentValue(DiagnosticBag diagnostics, ArgumentSyntax argumentSyntax, Boolean allowArglist, RefKind refKind) ...
[Fact] public void DefaultInAsOperatorWithReferenceType() { var text = @" class C { static void Main() { System.Console.Write(default as C); } }"; var comp = CreateCompilationWithMscorlib(text, parseOptions: TestOptions.ExperimentalParseOptions, options: TestOptions.DebugExe); comp.VerifyDiagnostics( // TODO ); }
The text was updated successfully, but these errors were encountered:
jcouv
No branches or pull requests
It's probably good to also test
default as T
whereT
is an open type.The text was updated successfully, but these errors were encountered: