Skip to content

Commit 533af3e

Browse files
author
Dart CI
committed
Version 3.9.0-234.0.dev
Merge 0070331 into dev
2 parents d806bca + 0070331 commit 533af3e

File tree

10 files changed

+124
-464
lines changed

10 files changed

+124
-464
lines changed

.gitattributes

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,20 +16,13 @@
1616

1717
# File that should not be converted.
1818
tests/web/eof_line_ending_test.dart -text
19-
tests/web/string_interpolation_test.dart -text
20-
tests/web/string_interpolation_dynamic_test.dart -text
21-
tests/web/literal_string_juxtaposition_test.dart -text
22-
tests/language/string/raw_string_test.dart -text
23-
tests/language/string/multiline_strings_test.dart -text
2419
tests/language/string/multiline_newline_cr.dart -text
2520
tests/language/string/multiline_newline_crlf.dart -text
2621
tests/language/string/multiline_newline_lf.dart -text
2722
tests/lib/mirrors/method_mirror_source_line_ending_cr.dart -text
2823
tests/lib/mirrors/method_mirror_source_line_ending_crlf.dart -text
2924
tests/lib/mirrors/method_mirror_source_line_ending_lf.dart -text
30-
tests/lib/mirrors/method_mirror_source_line_ending_test.dart -text
3125
tests/lib/mirrors/method_mirror_source_other.dart -text
32-
tests/lib/mirrors/method_mirror_source_test.dart -text
3326

3427
# Files to leave alone and not diff.
3528
*.png binary

DEPS

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -139,15 +139,15 @@ vars = {
139139
"leak_tracker_rev": "f5620600a5ce1c44f65ddaa02001e200b096e14c", # rolled manually
140140
"material_color_utilities_rev": "799b6ba2f3f1c28c67cc7e0b4f18e0c7d7f3c03e",
141141
"native_rev": "5eadfaf3b732bc512d327ac284b6f294bf05e4c2", # rolled manually while native assets are experimental
142-
"protobuf_rev": "32d53dad4565fc6ccd69196b8fd213454f3e8ed5",
142+
"protobuf_rev": "0bfff0ca150959c92dac525474d73bde946f3391",
143143
"pub_rev": "818f10b4bf9249bd0b2c212dd8709675eeb14cd2", # rolled manually
144144
"shelf_rev": "082d3ac2d13a98700d8148e8fad8f3e12a6fd0e1",
145145
"sync_http_rev": "dc54465f07d9652875deeade643256dafa2fbc6c",
146146
"tar_rev": "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a",
147147
"test_rev": "0793a2b3262ac900558c49c76e9bbe4f29f91ea4",
148-
"tools_rev": "e84cbd9e1b111d80763ae8b3e04685bd66866f08",
148+
"tools_rev": "72e6cc871a0dcb7e6b92c01a96503d1b6aebb5e3",
149149
"vector_math_rev": "13f185f7e97d559e003f5ac79201da12f9a01049",
150-
"web_rev": "de6b3e40826bde1653573d5c8e36aec3df2f4927",
150+
"web_rev": "c8c1c2852ace3bb78026dddc64b111051a7e855a",
151151
"webdev_rev": "661dafd4a050e4325253155af092d2243721ab28",
152152
"webdriver_rev": "b8f511d7719e2ae2c21eb4d94f68564eee32cbe2",
153153
"webkit_inspection_protocol_rev": "effa75205516757795683d527c3dea9546eb0c32",

sdk/lib/js_interop/js_interop.dart

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1388,11 +1388,14 @@ extension JSAnyOperatorExtension on JSAny? {
13881388
/// For example:
13891389
///
13901390
/// ```
1391+
/// library;
1392+
///
13911393
/// @JS()
13921394
/// external String get name;
13931395
/// ```
13941396
///
1395-
/// Reading `name` will execute JavaScript code like `globalContext.name`.
1397+
/// Reading the top-level member `name` will execute JavaScript code like
1398+
/// `<globalContext>.name`.
13961399
///
13971400
/// There are subtle differences depending on the compiler, but in general,
13981401
/// [globalContext] can be treated like JavaScript's `globalThis`.

tests/language/string/multiline_newline_cr.dart

Lines changed: 9 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -2,24 +2,16 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5-
library multiline_newline_cr;
5+
// Test depends on specific line endings,
6+
// and requires an entry in the .gitattributes file.
67

7-
const constantMultilineString = """
8-
a
9-
b
10-
""";
8+
// dart format off
119

12-
var nonConstantMultilineString = """
13-
a
14-
b
15-
""";
10+
// All line endings inside string literals are Carriage Return, U+000D
11+
const constantMultilineString = """ab""";
1612

17-
const constantRawMultilineString = r"""
18-
\a
19-
\b
20-
""";
13+
var nonConstantMultilineString = """ab""";
2114

22-
var nonConstantRawMultilineString = r"""
23-
\a
24-
\b
25-
""";
15+
const constantRawMultilineString = r"""\a\b""";
16+
17+
var nonConstantRawMultilineString = r"""\a\b""";

tests/language/string/multiline_strings_test.dart

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,24 +2,29 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5-
// Note: This test relies on LF line endings in the source file.
6-
75
import "package:expect/expect.dart";
86

9-
main() {
7+
void main() {
8+
// Spaces after '''.
109
Expect.equals('foo', '''
1110
foo''');
1211

12+
// Tab characters after '''.
13+
Expect.equals('foo', '''
14+
foo''');
15+
1316
Expect.equals('\\\nfoo', '''\\
1417
foo''');
1518

1619
Expect.equals('\t\nfoo', '''\t
1720
foo''');
1821

22+
// Backslash just before newline.
1923
Expect.equals('foo', '''\
2024
foo''');
2125

22-
Expect.equals('foo', '''\ \
26+
// Backslash before space, tab and newline.
27+
Expect.equals('foo', '''\ \ \
2328
foo''');
2429

2530
Expect.equals(' \nfoo', '''\x20
@@ -29,18 +34,25 @@ foo''');
2934
Expect.equals(' \nfoo', '''$x
3035
foo''');
3136

37+
/// Spaces after '''.
3238
Expect.equals('foo', r'''
3339
foo''');
3440

41+
/// Tab characters after '''.
42+
Expect.equals('foo', r'''
43+
foo''');
44+
3545
Expect.equals('\\\\\nfoo', r'''\\
3646
foo''');
3747

3848
Expect.equals('\\t\nfoo', r'''\t
3949
foo''');
4050

51+
// Backslash before newline.
4152
Expect.equals('foo', r'''\
4253
foo''');
4354

44-
Expect.equals('foo', r'''\ \
55+
// Backslash before space, tab and newline.
56+
Expect.equals('foo', r'''\ \ \
4557
foo''');
4658
}

tests/language/string/raw_string_test.dart

Lines changed: 28 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -2,48 +2,40 @@
22
// for details. All rights reserved. Use of this source code is governed by a
33
// BSD-style license that can be found in the LICENSE file.
44

5-
// Note: This test relies on LF line endings in the source file.
6-
75
import "package:expect/expect.dart";
86

9-
class RawStringTest {
10-
static testMain() {
11-
Expect.equals("abcd", r"abcd");
12-
Expect.equals("", r"");
13-
Expect.equals("", r'');
14-
Expect.equals("", r"""""");
15-
Expect.equals("", r'''''');
16-
Expect.equals("''''", r"''''");
17-
Expect.equals('""""', r'""""');
18-
Expect.equals("1\n2\n3", r"""1
7+
void main() {
8+
Expect.equals("abcd", r"abcd");
9+
Expect.equals("", r"");
10+
Expect.equals("", r'');
11+
Expect.equals("", r"""""");
12+
Expect.equals("", r'''''');
13+
Expect.equals("''''", r"''''");
14+
Expect.equals('""""', r'""""');
15+
Expect.equals("1\n2\n3", r"""1
1916
2
2017
3""");
21-
Expect.equals("1\n2\n3", r'''1
18+
Expect.equals("1\n2\n3", r'''1
2219
2
2320
3''');
24-
Expect.equals("1", r"""
21+
Expect.equals("1", r"""
2522
1""");
26-
Expect.equals("1", r'''
23+
Expect.equals("1", r'''
2724
1''');
28-
Expect.equals("'", r"'");
29-
Expect.equals('"', r'"');
30-
Expect.equals("1", r"1");
31-
Expect.equals("1", r"1");
32-
Expect.equals("\$", r"$");
33-
Expect.equals("\\", r"\");
34-
Expect.equals("\\", r'\');
35-
Expect.equals("\${12}", r"${12}");
36-
Expect.equals(
37-
"\\a\\b\\c\\d\\e\\f\\g\\h\\i\\j\\k\\l\\m",
38-
r"\a\b\c\d\e\f\g\h\i\j\k\l\m",
39-
);
40-
Expect.equals(
41-
"\\n\\o\\p\\q\\r\\s\\t\\u\\v\\w\\x\\y\\z",
42-
r"\n\o\p\q\r\s\t\u\v\w\x\y\z",
43-
);
44-
}
45-
}
46-
47-
main() {
48-
RawStringTest.testMain();
25+
Expect.equals("'", r"'");
26+
Expect.equals('"', r'"');
27+
Expect.equals("1", r"1");
28+
Expect.equals("1", r"1");
29+
Expect.equals("\$", r"$");
30+
Expect.equals("\\", r"\");
31+
Expect.equals("\\", r'\');
32+
Expect.equals("\${12}", r"${12}");
33+
Expect.equals(
34+
"\\a\\b\\c\\d\\e\\f\\g\\h\\i\\j\\k\\l\\m",
35+
r"\a\b\c\d\e\f\g\h\i\j\k\l\m",
36+
);
37+
Expect.equals(
38+
"\\n\\o\\p\\q\\r\\s\\t\\u\\v\\w\\x\\y\\z",
39+
r"\n\o\p\q\r\s\t\u\v\w\x\y\z",
40+
);
4941
}

0 commit comments

Comments
 (0)