Skip to content

Incorrect syntax highlighting after some preprocessor directives #1598

Open
@yodapuces63

Description

@yodapuces63

Describe the problem

After #elif and #error, the text are wrong coloured
see de screenshot

2022-10-29_18-36-00

To reproduce

Copy this in editor

//---Config pour l'ESP-----------------------
#ifdef ARDUINO_ESP8266_GENERIC
  #define ESPMOD      //pour module ESP12
  #define TelNetDEBUG       //mode TelNet debug (via port 23)
//#define CommErTRACE         //TRACE les compteurs d'erreures de comm

//---Config pour le ProMini------------------
#elif ARDUINO_AVR_PRO
  #define PROMOD      //pour module ProMini

#else
  #error              //Si pas une de ces deux carte => Stop la compilation
#endif

Expected behavior

#elif definition should be blue
#error //comment should be green

Arduino IDE version

2.0.1

Operating system

Windows

Operating system version

10

Additional context

Additional reports

Issue checklist

  • I searched for previous reports in the issue tracker
  • I verified the problem still occurs when using the latest nightly build
  • My report contains all necessary details

Metadata

Metadata

Assignees

No one assigned

    Labels

    topic: theiaRelated to the Theia IDE frameworktype: imperfectionPerceived defect in any part of project

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions