better-cpp-syntax icon indicating copy to clipboard operation
better-cpp-syntax copied to clipboard

For C, "alignas" macro gets tokenized as "a" and "lignas".

Open sean-mcmanus opened this issue 4 years ago • 0 comments

Checklist

  • [X] This problem exists even with the setting "C_Cpp.enhancedColorization": "Disabled"
  • [X] This bug exists for C
  • [no] This bug exists for C++
  • [?] This bug exists for Objective-C
  • [?] This bug exists for Objective-C++

The code with a problem is:

#include <stdalign.h>

int main(void)
{
    alignas(4) int y = sizeof(double);
}

It looks like:

** screenshot + theme name preferable ** Dark+ image

It should look like:

The "a" part should have the same scope as the "lignas" part (entity.name.function.c).

I hit this while investigating https://github.com/microsoft/vscode-cpptools/issues/6022 .

sean-mcmanus avatar Aug 25 '20 18:08 sean-mcmanus