Skip to content

Commit 3794264

Browse files
jensjohacommit-bot@chromium.org
authored andcommitted
[CFE] Forgotten test for external fields and advanced invalidation fix
This CL is a test I forgot to include in https://dart-review.googlesource.com/c/sdk/+/188461 even though I wrote it and used it to verify the fix. Better late than never. Change-Id: I6371719ce0d447f6ef9aeb6ebed2b7615c911b6d Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/190480 Reviewed-by: Johnni Winther <[email protected]> Commit-Queue: Jens Johansen <[email protected]>
1 parent 03ac05b commit 3794264

File tree

3 files changed

+49
-0
lines changed

3 files changed

+49
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Copyright (c) 2021, the Dart project authors. Please see the AUTHORS file
2+
# for details. All rights reserved. Use of this source code is governed by a
3+
# BSD-style license that can be found in the LICENSE.md file.
4+
5+
# Reproduce a crash.
6+
7+
type: newworld
8+
target: VM
9+
worlds:
10+
- entry: main.dart
11+
experiments: alternative-invalidation-strategy,non-nullable
12+
sources:
13+
main.dart: |
14+
class Foo {
15+
external int x;
16+
}
17+
expectedLibraryCount: 1
18+
19+
- entry: main.dart
20+
experiments: alternative-invalidation-strategy,non-nullable
21+
worldType: updated
22+
expectInitializeFromDill: false
23+
invalidate:
24+
- main.dart
25+
expectedLibraryCount: 1
26+
expectsRebuildBodiesOnly: true
27+
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
main = <No Member>;
2+
library from "org-dartlang-test:///main.dart" as main {
3+
4+
class Foo extends dart.core::Object {
5+
synthetic constructor •() → main::Foo
6+
: super dart.core::Object::•()
7+
;
8+
external get x() → dart.core::int;
9+
external set x(dart.core::int #externalFieldValue) → void;
10+
}
11+
}
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
main = <No Member>;
2+
library from "org-dartlang-test:///main.dart" as main {
3+
4+
class Foo extends dart.core::Object {
5+
synthetic constructor •() → main::Foo
6+
: super dart.core::Object::•()
7+
;
8+
external get x() → dart.core::int;
9+
external set x(dart.core::int #externalFieldValue) → void;
10+
}
11+
}

0 commit comments

Comments
 (0)