Skip to content

Conversation

@llvmbot
Copy link
Member

@llvmbot llvmbot commented Jun 10, 2025

Backport 77347d6

Requested by: @mstorsjo

@llvmbot
Copy link
Member Author

llvmbot commented Jun 10, 2025

@cjacek What do you think about merging this PR to the release branch?

@llvmbot llvmbot requested a review from cjacek June 10, 2025 09:20
@tstellar tstellar moved this from Needs Triage to Needs Review in LLVM Release Status Jun 11, 2025
@tstellar
Copy link
Collaborator

ping @cjacek

@github-project-automation github-project-automation bot moved this from Needs Review to Needs Merge in LLVM Release Status Jun 12, 2025
While
https://learn.microsoft.com/en-us/windows/win32/menurc/accelerators-resource
specifies that ALT only applies to virtkeys, this doesn't seem to be the
case in reality.

https://learn.microsoft.com/en-us/windows/win32/menurc/using-keyboard-accelerators
contains an example that uses this combination:

    "B",   ID_ACCEL5, ALT                   ; ALT_SHIFT+B

Also Microsoft also includes such cases in their repo of test cases:
https://github.com/microsoft/Windows-classic-samples/blob/263dd514ad215d0a40d1ec44b4df84b30ec11dcf/Samples/Win7Samples/begin/sdkdiff/sdkdiff.rc#L161-L164

Also MS rc.exe doesn't warn/error about this. However if applying SHIFT
or CONTROL on a non-virtkey accelerator, MS rc.exe does produce this
warning:

    warning RC4203 : SHIFT or CONTROL used without VIRTKEY

Hence, keep the checks for SHIFT and CONTROL, but remove the checks for
ALT, which seems to have been incorrect.

This fixes one aspect of
llvm#143157.

(cherry picked from commit 77347d6)
@tstellar tstellar merged commit c4f257c into llvm:release/20.x Jun 12, 2025
6 of 7 checks passed
@github-project-automation github-project-automation bot moved this from Needs Merge to Done in LLVM Release Status Jun 12, 2025
@github-actions
Copy link

@mstorsjo (or anyone else). If you would like to add a note about this fix in the release notes (completely optional). Please reply to this comment with a one or two sentence description of the fix. When you are done, please add the release:note label to this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

4 participants