Skip to content

Fix 'move type' with file scoped namespaces#55020

Merged
CyrusNajmabadi merged 4 commits intodotnet:mainfrom
CyrusNajmabadi:fileScopedNamespaceMoveType
Jul 22, 2021
Merged

Fix 'move type' with file scoped namespaces#55020
CyrusNajmabadi merged 4 commits intodotnet:mainfrom
CyrusNajmabadi:fileScopedNamespaceMoveType

Conversation

@CyrusNajmabadi
Copy link
Copy Markdown
Contributor

@CyrusNajmabadi CyrusNajmabadi commented Jul 21, 2021

Relates to test plan: #49000

@CyrusNajmabadi CyrusNajmabadi requested a review from ryzngard July 21, 2021 19:05
@CyrusNajmabadi CyrusNajmabadi requested a review from a team as a code owner July 21, 2021 19:05
@ghost ghost added the Area-IDE label Jul 21, 2021
@dotnet dotnet deleted a comment from azure-pipelines bot Jul 21, 2021
@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 3 pipeline(s).

}

[WpfFact, Trait(Traits.Feature, Traits.Features.CodeActionsMoveType)]
public async Task MoveTypeWithWithFileScopedNamespace()
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Can you add a tests for moving Class1 and Class2 with this setup? Assuming this is valid with filescoped namespaces

namespace N1;

class Class1 
{
    Nested.Class2 C2 { get; }
}

namespace Nested
{
    class Class2 { }
}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

that's not valid. it's illegal to mix/match a file-scoped namespace with any other sort of namespace (including another file scoped namespace).

@CyrusNajmabadi
Copy link
Copy Markdown
Contributor Author

/azp run

@CyrusNajmabadi CyrusNajmabadi enabled auto-merge July 21, 2021 21:12
@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 3 pipeline(s).

@CyrusNajmabadi CyrusNajmabadi requested a review from ryzngard July 22, 2021 00:55
@CyrusNajmabadi
Copy link
Copy Markdown
Contributor Author

ping @ryzngard

@CyrusNajmabadi CyrusNajmabadi merged commit 91d692f into dotnet:main Jul 22, 2021
@ghost ghost added this to the Next milestone Jul 22, 2021
@CyrusNajmabadi CyrusNajmabadi deleted the fileScopedNamespaceMoveType branch July 22, 2021 18:56
@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.

4 participants