@@ -13,6 +13,8 @@ class BytecodeOptions {
13
13
'instance-field-initializers' : 'Emit separate instance field initializers' ,
14
14
'keep-unreachable-code' :
15
15
'Do not remove unreachable code (useful if collecting code coverage)' ,
16
+ 'closure-context-lowering' :
17
+ 'Use the closure context lowering in Kernel AST instead of computing it' ,
16
18
};
17
19
18
20
bool enableAsserts;
@@ -24,6 +26,7 @@ class BytecodeOptions {
24
26
bool omitAssertSourcePositions;
25
27
bool keepUnreachableCode;
26
28
bool showBytecodeSizeStatistics;
29
+ bool isClosureContextLoweringEnabled;
27
30
28
31
BytecodeOptions ({
29
32
this .enableAsserts = false ,
@@ -35,6 +38,7 @@ class BytecodeOptions {
35
38
this .omitAssertSourcePositions = false ,
36
39
this .keepUnreachableCode = false ,
37
40
this .showBytecodeSizeStatistics = false ,
41
+ this .isClosureContextLoweringEnabled = false ,
38
42
}) {}
39
43
40
44
void parseCommandLineFlags (List <String >? flags) {
@@ -64,6 +68,9 @@ class BytecodeOptions {
64
68
case 'show-bytecode-size-stat' :
65
69
showBytecodeSizeStatistics = true ;
66
70
break ;
71
+ case 'closure-context-lowering' :
72
+ isClosureContextLoweringEnabled = true ;
73
+ break ;
67
74
default :
68
75
throw 'Unexpected bytecode flag $flag ' ;
69
76
}
0 commit comments