Index: pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/operations.dart |
diff --git a/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/operations.dart b/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/operations.dart |
index 91f541ea3cf5789bb0091a2c03ac2ee745ba91be..13d0a3ad42d88ff38422430377d02bb3db3d343f 100644 |
--- a/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/operations.dart |
+++ b/pkg/dev_compiler/tool/input_sdk/private/ddc_runtime/operations.dart |
@@ -858,9 +858,9 @@ constList(elements, elementType) => JS('', '''(() => { |
let value = map.get($elementType); |
if (value) return value; |
- value = $setType($elements, ${getGenericClass(JSArray)}($elementType)); |
- map.set($elementType, value); |
- return value; |
+ ${getGenericClass(JSArray)}($elementType).unmodifiable($elements); |
+ map.set($elementType, elements); |
+ return elements; |
})()'''); |
// The following are helpers for Object methods when the receiver |