File: features_expected.js

package info (click to toggle)
chromium 138.0.7204.183-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 6,071,908 kB
  • sloc: cpp: 34,937,088; ansic: 7,176,967; javascript: 4,110,704; python: 1,419,953; asm: 946,768; xml: 739,971; pascal: 187,324; sh: 89,623; perl: 88,663; objc: 79,944; sql: 50,304; cs: 41,786; fortran: 24,137; makefile: 21,806; php: 13,980; tcl: 13,166; yacc: 8,925; ruby: 7,485; awk: 3,720; lisp: 3,096; lex: 1,327; ada: 727; jsp: 228; sed: 36
file content (146 lines) | stat: -rw-r--r-- 2,114 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
// Copyright 2025 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

// Original: language/features.js
(() => {
  let v = 2 ** 2;
  v **= 3;
})();
(() => {
  async function* foo1() {
    await 42;
    yield 0;
  }
  async function foo2() {
    for await (let a of b) {
      bar1(x);
    }
  }
})();
(() => {
  /./s;
  /./su;
})();
(() => {
  let v = /(?<month>\d{2})-(?<day>\d{2})/;
  v.exec("11-11").groups.month;
})();
(() => {
  let {
    a,
    ...b
  } = {
    x: 1,
    y: 2,
    z: 3
  };
  let v = {
    a,
    ...b
  };
})();
(() => {
  try {
    throw 0;
  } catch {
    foo();
  } finally {
    bar();
  }
})();
(() => {
  "a
b";
})();
(() => {
  let v1 = 6n;
  let v2 = BigInt(1234546) + v1;
  let v3 = 0b1000011n;
})();
(() => {
  object.foo ?? "42";
})();
(() => {
  const obj = {
    foo: {
      bar: 42
    }
  };
  obj?.foo?.bar;
  obj?.meh?.bar;
  obj?.meh?.bar();
})();
(() => {
  let v1 = 1_000_000_000_000;
  let v2 = 0b1010_0001;
})();
(() => {
  let v = false;
  v ||= true;
})();
(() => {
  class Foo {
    #xValue = 0;
    get #x() {
      return this.#xValue;
    }
    set #x(value) {
      this.#xValue = value;
    }
    #inc() {
      this.#x++;
    }
    baz(obj) {
      return #xValue in obj;
    }
  }
})();
(() => {
  class Foo {
    prop = "42";
    fun = () => {
      return this.prop;
    };
    static staticProp = "42";
    static staticFun = function () {
      return Foo2.staticProp;
    };
  }
})();
(() => {
  class Foo {
    static #a = 42;
    static b;
    static {
      this.b = bar(this.#a);
    }
  }
})();
(() => {
  /[\p{Decimal_Number}&&\p{ASCII}]/v;
})();
(() => {
  let v = /(?<month>\d{2})-(?<year>\d{4})|(?<year>\d{4})-(?<month>\d{2})/;
  v.exec("11-1111").groups.year;
})();
(() => {
  /(?i:a)a/;
  /(?m:^a)a/;
  /(?s:.)./;
  /(?im:^a)a/;
})();
(() => {
  let v = do {
    if (v) {
      "1";
    } else {
      "2";
    }
  };
})();
(() => {
  async function foo() {
    using sync = openSync();
    await using async = await openAsync();
  }
})();