Skip to content

"Unexpected Null" dialog (and consequences) in Visual Studio when using Refactor, Extract Method #7364

@leppie

Description

@leppie

Repro in VS2015 Update 1 (not sure if others are affected):

In src\Compilers\CSharp\Portable\Binder\Binder_Symbols.cs, add the following on line 1835:

void Foo(

Now select the ternary expression just above it (between return and ;). Do Refactor, Extract Method.

An error dialog appears, stating 'Unexpected Null'.

image

Close the dialog, and open another a file. This file's editor is now seemingly readonly (till you close and re-open again).

Not sure if this is caused by Roslyn.

Metadata

Metadata

Labels

Area-IDEBugDeveloper CommunityThe issue was originally reported on https://developercommunity.visualstudio.comResolution-FixedThe bug has been fixed and/or the requested behavior has been implemented_Product-level triaged

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions