Keil Logo

Dynamic Syntax Checking

Dynamic Syntax Checking validates the program syntax while typing code and provides real-time alerts to potential code violations.

Enable Dynamic Syntax Checking using the dialog Edit - Configurations - Text Completion.

Potential errors or warnings are visualized through squiggly, red lines in the editor and icons in the editor margin. To view details, point with the mouse on an icon in the editor margin.

Dynamic Syntax Checking

Icons on the left editor margin identify:

  • Warning icon - Warning
  • Error icon - Error

Potential syntax errors and warnings can be viewed also from View - Error List Window. Double-click a row in the table to jump to the code line.

Dynamic Error and Warning List window


<first column> - Error indicator
W - Warning indicator
<filname>: Errors: i - Warnings: j Text identifying the error or warning.
File File in which the exception occurred.
Line Line number of the exception.


  • Errors and warnings appear in the order they have been created.
  • Errors and warnings are based on a partial compilation of the current module. Consequently, the result can differ from a full compilation.

Inactive source code

Dynamic Syntax Checking is also used to grey-out inactive source code:

Inactive source code

Source code that is marked as inactive is excluded by the compiler by using preprocessor directives such as #if, #ifdef, #elif, and #endif.


  • This feature may not work as expected for header files. The evaluation of conditions depends on the context in which the header file is included. If included from multiple source files, only a single context is evaluated and displayed in the editor.
  • The dependencies and information about include file chains are taken from the dependency files created by the compiler. If the compiler has not created any dependency files yet, the header file is processed without context, which may also lead to unexpected behavior.
  • This feature is enabled as soon as Dynamic Syntax Checking is enabled. You cannot enable/disable it separately.
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.