| Index: sdk/lib/_internal/lib/foreign_helper.dart
|
| diff --git a/sdk/lib/_internal/lib/foreign_helper.dart b/sdk/lib/_internal/lib/foreign_helper.dart
|
| index 73e3c09498b0954bec7eb4547ef9aa08b6969c01..4ab3cab667f7ce97945084428b50c2e1cb4f4d99 100644
|
| --- a/sdk/lib/_internal/lib/foreign_helper.dart
|
| +++ b/sdk/lib/_internal/lib/foreign_helper.dart
|
| @@ -236,3 +236,19 @@ JS_GLOBAL_OBJECT() {}
|
| * Obtain [name] from Namer.
|
| */
|
| String JS_GET_NAME(String name) {}
|
| +
|
| +/**
|
| + * Pretend [code] is executed. Generates no executable code. This is used to
|
| + * model effects at some other point in external code. For example, the
|
| + * following models an assignment to foo with an unknown value.
|
| + *
|
| + * var foo;
|
| + *
|
| + * main() {
|
| + * JS_EFFECT((_){ foo = _; })
|
| + * }
|
| + *
|
| + * TODO(sra): Replace this hack with something to mark the volatile or
|
| + * externally initialized elements.
|
| + */
|
| +void JS_EFFECT(Function code) { code(null); }
|
|
|