<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/64002>64002</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
llvm-rc: modifiers should be allowed for non-VIRTKEYS
</td>
</tr>
<tr>
<th>Labels</th>
<td>
new issue
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
pjanx
</td>
</tr>
</table>
<pre>
This check is wrong:
```
if (!IsVirtKey && (Obj.Flags & (Opt::ALT | Opt::SHIFT | Opt::CONTROL)))
return createAccError("Can only apply ALT, SHIFT or CONTROL to VIRTKEY"
" accelerators");
```
The documentation for those options might want you to believe this handling is correct, but it also immediately disagrees with itself—see IDDELLIPSE in [the follow-up example](https://learn.microsoft.com/en-us/windows/win32/menurc/accelerators-resource#examples).
Neither MSVC nor windres have an issue with it.
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxsU12P4jgQ_DXOSwsU2gTIQx4YIDq03M5pQSPdo2M3ieccO7KdYfn3J2eyt3enjax8lOLq6qq2CEG3lqhixQsrjpkYY-d8NbwL-z1rnHpWt04HkB3Jv0AHeHhnW8b3LD-yfM82-bymTwB9B4Y7hqtzeNM-fqEnMNww3CT4tXlf1ka0AX4AQ0xUfL-_3IBtD_APcP3tXP8POrx-vX17vTAs5zWXBPAUR29BehKR9lKevHd-koEHYcFZ8wQxDOYJ-8uN4QE-2Z2HmROig7fzt9uX058M8Sfxry-GCEJKMuRFdD6kLVgy_vJLT24dgXJy7MlGEbWzcHceYucCgRsSEKDXbRfhIWyEpxuTmoaMpg-CmMzvhFVG2zb5L533JGPqohkj6AjCBAe670lpEck8QekgWk8U4KFjBzoGMnd2QrbLWbkORHA-Hk-Xy_mP6wm0BVa8xI7g7oxxj8U4AH0X_WCIFUeGuy7GIaQEsGZYGxLeLnstvQvuHpfS9QxrsosxMKwf2ir3mN84Mqx7sqOXDOt_G7bwFNzoJTHkc63AsFzO_k33r6RjRx5-v74dwDoPidtTMuODQFjQIYz0o8NlpiquSl6KjKrVZleWnJccs65SxSbf0oqvS75rUDXbeyOJFyu-3ipqFGa6whx5vsXVKs8LjktOSip-V7xQ2OTliq1z6oU2S2M--qXzbTaVrjbrPMfMiIZMmE4PoqXHp640EsUx81Xas2jGNrB1bnSI4SdL1NHQ5w9eMr6H3il91-QDhM6NRkFDIFImpKaZsc4u5im9ZqM31X-jaXXsxmZOJNHOj8Xg3fs0MvWkLcUzaf87AAD__-X7PPQ">