Remove many alternate codepaths for _CRT_APP and _ONECORE#6190
Merged
StephanTLavavej merged 13 commits intomicrosoft:mainfrom Apr 2, 2026
Merged
Remove many alternate codepaths for _CRT_APP and _ONECORE#6190StephanTLavavej merged 13 commits intomicrosoft:mainfrom
_CRT_APP and _ONECORE#6190StephanTLavavej merged 13 commits intomicrosoft:mainfrom
Conversation
zacklj89
approved these changes
Mar 31, 2026
Member
Author
|
I'm mirroring this to the MSVC-internal repo. Please notify me if any further changes are pushed, otherwise no action is required. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
As I mentioned in #6187, we don't need most of our
_CRT_APPguards anymore. @amyw-msft explained:I understand
_ONECOREless, and I believe our codebase has been equally confused about the difference, but I believe that we can also remove most of those guards too. Since deployment time blocks are a thing of the past, I think we can rely on "if it builds, it's good". (My internal MSVC-PR-632910 merged on 2025-05-05 got our build using the WinSDK'smincore.libfor OneCore builds, instead of weird "mystery meat" libs, increasing my confidence that our builds are cromulent.)Getting rid of these alternate codepaths increases maintainability (since we almost exclusively test desktop configurations). In a few cases they may even improve functionality (e.g. by preferentially using
GetTempPath2W). I want to merge this at the beginning of the 14.52 cycle, so if we discover problems, we can easily revert part or all of these changes.Commits
CreateSymbolicLinkW.CreateHardLinkW.CreateDirectoryExW.CreateSymbolicLinkW.CreateHardLinkW._wgetcwd._wchdir.CreateSymbolicLinkW.GetModuleHandleExW.AreFileApisANSI.AreFileApisANSI.GetModuleHandleWto loadGetTempPath2W.GetModuleHandleWto loadGetTempPath2W.This has passed an internal build and
stlimporttest pass.