Skip to content

MSBuild is still opt'ing into the legacy GetFullPath behavior #2338

@davkean

Description

@davkean

.NET Framework recently made a change in 4.6.2 that improved the overhead of Path.GetFullPath by reducing the amount of processing within .NET itself, and letting it be handled by the operating system.

While MSBuild has their own version of GetFullPath (which should also be considered to be moved to the new GetFullPath), they are indirectly using the legacy behavior via Directory.GetFiles/GetDirectories, MSBuild should opt into the new behavior when running on 4.6.2 and above:

<?xml version="1.0" encoding="utf-8" ?>
<configuration>
  <runtime>
    <AppContextSwitchOverrides value="Switch.System.IO.UseLegacyPathHandling=false" />
  </runtime>
</configuration>

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions