How come there's no syntax error?

已回答

Hi

I've noticed that the IDE editor doesn't throw up syntax errors when there are clearly some. For instance, in this C file:

`static` and `false` are misspelt. How come there's no syntax error? I've already invalidated the cache and restarted CLion several times.

Thanks

1

This feature works in CLion only if your file is included in your project (in CMakeLists.txt). On your example, it seems that the file isn't included in the project so most of the errors are not shown.

0
Avatar
Permanently deleted user

Making a CMakeLists.txt file to get syntax highlighting for a random c file doesn't seem reasonable. If it's not going to be enabled by default there should at least be a simple toggle to turn it on.

0

请先登录再写评论。