This is the same problem you reported last year. The solution was for the header with the nested structs to be in ANSI-C mode, since it is ANSI-C, not C++. "struct but" is not visible outside of "struct pwm" in C++, so the symbol coloring is correct to flag those as unknown symbols.

We can't realistically deal with every combination of compiler extensions. We try, but this particular case is inherently ambiguous, so we have to pick a direction: ANSI-C mode does what it is supposed to do, C++ does what it is supposed to do. You kind of have to assess the same choice and decide if you are writing C++ or ANSI-C, or non-standard code that you should expect to be problematic for other compilers and tools. If it were my choice, I'd go the C++ direction and properly qualify the type names the way they are nested.