Improve "~const is not allowed here" message
#103319
Merged
~const is not allowed here" message
#103319