> On 24 Oct 2018, at 02:39, Paul Eggert <[email protected]> wrote:
> 
> On 10/22/18 8:52 AM, Akim Demaille wrote:
>> +          const int yylhs = yyr1[yyrule] - YYNTOKENS;
> 
> I used to work with someone who liked to declare C local variables 'register 
> const': 'register' so that he wasn't tempted to take the variable's address, 
> and 'const' so that he wasn't tempted to modify the variable. I tried to talk 
> him out of it, because to me 'register' and 'const' are complete overkill for 
> local variables; the compiler and the human reader can easily deduce these 
> properties statically, and they're not worth the valuable screen real estate 
> that they take up. But I couldn't talk him into it, so 'register const int 
> this' and 'register const int that' it was.

The keyword "register" has been deprecated in C++17, which is problem with Flex 
that writes it.

https://en.cppreference.com/w/cpp/keyword/register



Reply via email to