Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass through folders for additional files #71061

Conversation

jasonmalinowski
Copy link
Member

@jasonmalinowski jasonmalinowski commented Dec 2, 2023

Our workspace model always allowed this at the document level, we just never had a request for it until recently for some XAML support. This adds support for legacy project systems in VS and the base C# extension project system. Changes will need to be made in other repos for the CPS-based project systems to consume the APIs being added here.

Partially fixes #65589

Our workspace model always allowed this at the document level, we just
never had a request for it until recently for some XAML support. This
adds support for legacy project systems in VS and the base C# extension
project system. Changes will need to be made in other repos for the
CPS-based project systems to consume the APIs being added here.

Partially fixes dotnet#65589
@jasonmalinowski jasonmalinowski requested a review from a team as a code owner December 2, 2023 01:02
@dotnet-issue-labeler dotnet-issue-labeler bot added Area-IDE untriaged Issues and PRs which have not yet been triaged by a lead labels Dec 2, 2023
@jasonmalinowski jasonmalinowski self-assigned this Dec 2, 2023
@jasonmalinowski jasonmalinowski removed the untriaged Issues and PRs which have not yet been triaged by a lead label Dec 2, 2023
void AddAdditionalFile(string filePath, bool isInCurrentContext = true);
void AddAdditionalFile(string filePath, IEnumerable<string> folderNames, bool isInCurrentContext = true);
Copy link
Contributor

Choose a reason for hiding this comment

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

The other folderNames are nullable but not this one. Why?

Copy link
Member Author

Choose a reason for hiding this comment

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

If that was also made nullable and optional, then a call of AddAdditionalFile("File.txt") was ambiguous between the two calls, since there's no special logic for the compiler to ignore Obsolete methods in that case. Conveniently the compiler is thinking about that so that's good. 😄

@jasonmalinowski jasonmalinowski merged commit 3d13136 into dotnet:main Dec 4, 2023
24 checks passed
@jasonmalinowski jasonmalinowski deleted the include-folder-information-for-additional-files branch December 4, 2023 22:47
@ghost ghost added this to the Next milestone Dec 4, 2023
@Cosifne Cosifne modified the milestones: Next, 17.9 P3 Jan 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TextDocument.Folders is always empty for additional files
4 participants