[JS IR] Generate special region comments at the start and the end of each file block

It allows to fold these blocks and navigate to them in the IDEA.

Also, this commit adds compiler configuration keys to control generating comments with paths for file blocks,
and now generating such comments is enabled only in our tests.
This commit is contained in:
Zalim Bashorov
2019-11-20 22:44:28 +03:00
parent fa76b9cf83
commit c05c07f243
3 changed files with 67 additions and 16 deletions
@@ -75,4 +75,10 @@ public class JSConfigurationKeys {
public static final CompilerConfigurationKey<Boolean> DEVELOPER_MODE =
CompilerConfigurationKey.create("enables additional checkers");
public static final CompilerConfigurationKey<Boolean> GENERATE_COMMENTS_WITH_FILE_PATH =
CompilerConfigurationKey.create("generate comments with file path at the start of each file block");
public static final CompilerConfigurationKey<Boolean> GENERATE_REGION_COMMENTS =
CompilerConfigurationKey.create("generate special comments at the start and the end of each file block, it allows to fold them and navigate to them in the IDEA");
}