Missing #endif directive before the closing curly brace

Description

See this sample:

The #endif directive is missing in the converter output.

Environment

None

Activity

Show:
Alex Petuschak
August 10, 2020, 2:38 PM

This seems related to both your changes (in ) and (and old, and difficult issues).

Let me know if you see a solution here.

If difficult, this could be postponed.

See `Backup/MissingDirectives` branch for related changes from SWC-801, some were included and some were not.

Dmitry Rassadin
August 11, 2020, 12:40 AM

Some code fragments aren’t fully obvious, but I got the thought that some hidden tokens might be skipped unintentionally.

I fixed example’s case via manually hidden tokens extraction of RBRACE(“}”) token from instanceVariables parser rule. Basically, I’d rather create some parser rule/predicate which matches RBRACEsin particular(I’m not sure it’s necessary for all RBRACEs occurrences) and do process those hidden tokens.

Alex Petuschak
August 12, 2020, 4:20 PM

Your fix for this specific case looks like a minimally accepted version.

If you have time for a more generic solution, that would be awesome.

Otherwise, just put this task in review, and we will revisit the generic case solution later.

Assignee

Serhii Kuzmychov

Reporter

Alex Petuschak

Labels

None

Git Branch Name

None

GitHub Issue

None

Components

Fix versions

Priority

Medium
Configure