Index: tests/compiler/dart2js/class_codegen2_test.dart |
diff --git a/tests/compiler/dart2js/class_codegen2_test.dart b/tests/compiler/dart2js/class_codegen2_test.dart |
index 730a59a3983e2e173400a9c9147943b9bf0f21ae..91b6b97f731ba25179817afd23dea4d8bbcda694 100644 |
--- a/tests/compiler/dart2js/class_codegen2_test.dart |
+++ b/tests/compiler/dart2js/class_codegen2_test.dart |
@@ -85,7 +85,7 @@ main() { |
main() { |
// At some point Dart2js generated bad object literals with dangling commas: |
// { a: true, }. Make sure this doesn't happen again. |
- RegExp danglingComma = new RegExp(r',[ \n]*}'); |
+ RegExp danglingComma = const RegExp(r',[ \n]*}'); |
String generated = compileAll(TEST_ONE); |
Expect.isFalse(danglingComma.hasMatch(generated)); |