Skip to content

Commit

Permalink
Update test refs
Browse files Browse the repository at this point in the history
  • Loading branch information
kdy1 committed Jul 29, 2022
1 parent 708de93 commit 500c77d
Show file tree
Hide file tree
Showing 44 changed files with 122 additions and 68 deletions.
Expand Up @@ -3,7 +3,7 @@ var M, ANY2 = [
""
], obj1 = {
x: "",
y () {}
y: ()=>{}
};
class A {
static foo() {}
Expand Down
Expand Up @@ -4,6 +4,6 @@ foo(1), foo(), f(1), f(), f2(1), f2(1, 2), c.foo(), c.foo(1), i(), i(1), i.foo(1
var b = {
foo (x) {},
a: function(x, y) {},
b (x) {}
b: (x)=>{}
};
b.foo(), b.foo(1), b.a(1), b.a(1, 2), b.b(), b.b(1);
Expand Up @@ -4,7 +4,9 @@ var A = function() {
this.b = 2;
};
exports.A = A, exports.B = B, A.prototype = B.prototype = {
m: (n)=>n + 1
m (n) {
return n + 1;
}
};
var mod = require('./mod'), a = new mod.A(), b = new mod.B();
a.m('nope'), b.m('not really');
Expand Up @@ -5,10 +5,14 @@ Object.defineProperty(exports, "thing", {
value: "Smith",
writable: !1
}), Object.defineProperty(exports, "rwAccessors", {
get: ()=>98122,
get () {
return 98122;
},
set (_) {}
}), Object.defineProperty(exports, "readonlyAccessor", {
get: ()=>21.75
get () {
return 21.75;
}
}), Object.defineProperty(exports, "setonlyAccessor", {
set (str) {
this.rwAccessors = Number(str);
Expand All @@ -21,10 +25,14 @@ Object.defineProperty(module.exports, "thing", {
value: "Smith",
writable: !1
}), Object.defineProperty(module.exports, "rwAccessors", {
get: ()=>98122,
get () {
return 98122;
},
set (_) {}
}), Object.defineProperty(module.exports, "readonlyAccessor", {
get: ()=>21.75
get () {
return 21.75;
}
}), Object.defineProperty(module.exports, "setonlyAccessor", {
set (str) {
this.rwAccessors = Number(str);
Expand Down
Expand Up @@ -10,10 +10,14 @@ Person.prototype.describe = function() {
value: "Smith",
writable: !1
}), Object.defineProperty(Person.prototype, "rwAccessors", {
get: ()=>98122,
get () {
return 98122;
},
set (_) {}
}), Object.defineProperty(Person.prototype, "readonlyAccessor", {
get: ()=>21.75
get () {
return 21.75;
}
}), Object.defineProperty(Person.prototype, "setonlyAccessor", {
set (str) {
this.rwAccessors = Number(str);
Expand Down
@@ -1,7 +1,9 @@
const obj = {
foo: void 0,
bar: "42",
method1: (n1)=>n1 + 42,
method1 (n1) {
return n1 + 42;
},
lol: "hello Lol",
bar1: 42,
arrowFunc: (num)=>num + 42
Expand Down
@@ -1,7 +1,9 @@
var lol;
const obj = {
bar: 42,
method1: (n1)=>"42",
method1 (n1) {
return "42";
},
method2: (n1)=>"lol",
arrowFunc: (num = "0")=>num + 42,
lol
Expand Down
Expand Up @@ -8,10 +8,14 @@ Object.defineProperty(x, "name", {
value: "Smith",
writable: !1
}), Object.defineProperty(x, "zip", {
get: ()=>98122,
get () {
return 98122;
},
set (_) {}
}), Object.defineProperty(x, "houseNumber", {
get: ()=>21.75
get () {
return 21.75;
}
}), Object.defineProperty(x, "zipStr", {
set (str) {
this.zip = Number(str);
Expand Down
Expand Up @@ -8,7 +8,9 @@ Object.defineProperty(exports, "thing", {
value: 42,
writable: !0
}), Object.defineProperty(exports, "bad1", {}), Object.defineProperty(exports, "bad2", {
get: ()=>12,
get () {
return 12;
},
value: "no"
}), Object.defineProperty(exports, "bad3", {
writable: !0
Expand Down
Expand Up @@ -4,7 +4,9 @@ import _class_private_field_set from "@swc/helpers/src/_class_private_field_set.
let friendA;
var _x = new WeakMap();
friendA = {
getX: (obj)=>_class_private_field_get(obj, _x),
getX (obj) {
return _class_private_field_get(obj, _x);
},
setX (obj, value) {
_class_private_field_set(obj, _x, value);
}
Expand Down
@@ -1,6 +1,6 @@
foo({
p: "",
0 () {},
0: ()=>{},
hibye: !0,
1: 0,
[NaN]: [
Expand Down
@@ -1,6 +1,6 @@
foo({
p: "",
0 () {},
0: ()=>{},
hibye: !0,
1: 0,
[NaN]: [
Expand Down
@@ -1,5 +1,5 @@
foo({
0 () {},
0: ()=>{},
hibye: !0,
1: 0,
[NaN]: [
Expand Down
@@ -1,5 +1,5 @@
foo({
0 () {},
0: ()=>{},
hibye: !0,
1: 0,
[NaN]: [
Expand Down
@@ -1,4 +1,6 @@
var x = {
a: (p)=>p
a (p) {
return p;
}
};
x.a(x);
Expand Up @@ -4,7 +4,7 @@ export function MainButton(props) {
return props.goTo ? this._buildMainLink(props) : this._buildMainButton(props);
}
_extends({}, {
onClick (k) {
onClick: (k)=>{
console.log(k);
}
}, {
Expand All @@ -16,7 +16,7 @@ _extends({}, {
});
export function NoOverload() {}
_extends({}, {
onClick (k) {
onClick: (k)=>{
console.log(k);
}
}, {
Expand Down
@@ -1,6 +1,8 @@
const TopLevelSym = Symbol(), InnerSym = Symbol();
module.exports = {
[TopLevelSym]: (x = 12)=>x,
[TopLevelSym] (x = 12) {
return x;
},
items: {
[InnerSym]: (arg = {
x: 12
Expand Down
Expand Up @@ -9,5 +9,7 @@ function Context(input) {
this.state = this.construct(input);
}
Context.prototype = {
construct: (input, handle = ()=>void 0)=>input
construct (input, handle = ()=>void 0) {
return input;
}
}, module.exports = Context;
Expand Up @@ -15,7 +15,9 @@ export class C {
export class D {
}
Object.defineProperty(D.prototype, "x", {
get: ()=>12
get () {
return 12;
}
});
export class E {
}
Expand All @@ -25,6 +27,8 @@ Object.defineProperty(E.prototype, "x", {
export class F {
}
Object.defineProperty(F.prototype, "x", {
get: ()=>12,
get () {
return 12;
},
set (_arg) {}
});
Expand Up @@ -2,9 +2,9 @@ var E, Flag;
!function(E) {
E[E.A = 0] = "A", E[E.B = 1] = "B", E[E.C = 2] = "C";
}(E || (E = {})), one(()=>{}), on({
test () {}
test: ()=>{}
}), on({
test (x) {}
test: (x)=>{}
}), new Component1({
data: {
hello: ""
Expand Down
Expand Up @@ -3,7 +3,7 @@ var M, ANY2 = [
""
], obj1 = {
x: "",
y () {}
y: ()=>{}
};
class A {
static foo() {}
Expand Down
Expand Up @@ -15,7 +15,9 @@ let o = {
explicitThis: function(m) {
return m + this.n.length;
},
implicitThis: (m)=>m
implicitThis (m) {
return m;
}
}, i = o;
(0, i.explicitThis)(12), (0, (void 0).implicitNoThis)(12), c.explicitVoid = c.implicitThis, o.implicitThis = c.implicitThis, o.implicitThis = c.explicitThis, o.implicitThis = i.explicitThis, i.explicitThis = function(m) {
return this.n.length;
Expand Down
Expand Up @@ -3,7 +3,7 @@ var M, ANY2 = [
""
], obj1 = {
x: "",
y () {}
y: ()=>{}
};
class A {
static foo() {}
Expand Down
Expand Up @@ -2,9 +2,11 @@ registerComponent('test-component', {
schema: {
myProperty: {
default: [],
parse: ()=>[
parse () {
return [
!0
]
];
}
},
string: {
type: 'string'
Expand Down
Expand Up @@ -2,7 +2,7 @@ class A {
}
c.valueOf(), c.data.hm, c.hm, i.valueOf(), i.data.hm, i.hm;
var c, i, b, a = {
valueOf () {},
valueOf: ()=>{},
data: new class extends A {
}()
};
Expand Down
@@ -1,4 +1,4 @@
var i, b;
(void 0).valueOf(), i.valueOf(), ({
valueOf () {}
valueOf: ()=>{}
}).valueOf(), b.valueOf();
Expand Up @@ -2,8 +2,8 @@ var M, ANY2 = [
"",
""
], obj1 = {
x (s) {},
y (s1) {}
x: (s)=>{},
y: (s1)=>{}
};
class A {
static foo() {}
Expand Down
Expand Up @@ -5,7 +5,7 @@ import _class_static_private_method_get from "@swc/helpers/src/_class_static_pri
class A3 {
constructor(a, b){
_class_static_private_field_spec_set(A3, A3, _method, ()=>{}), _class_static_private_field_spec_set(a, A3, _method, ()=>{}), _class_static_private_field_spec_set(b, A3, _method, ()=>{}), ({ x: _class_static_private_field_destructure(A3, A3, _method).value } = {
x () {}
x: ()=>{}
}), _class_static_private_method_get(A3, A3, function() {}), _class_static_private_field_update(b, A3, _method).value++;
}
}
@@ -1,6 +1,8 @@
var i = {
[Symbol.iterator]: 0,
[Symbol.toStringTag]: ()=>"",
[Symbol.toStringTag] () {
return "";
},
set [Symbol.toPrimitive] (p){}
};
i[Symbol.iterator], i[Symbol.toStringTag](), i[Symbol.toPrimitive] = !1;
Expand Up @@ -2,8 +2,10 @@ var i = {
[Symbol.iterator]: {
p: null
},
[Symbol.toStringTag]: ()=>({
[Symbol.toStringTag] () {
return {
p: void 0
})
};
}
};
i[Symbol.iterator], i[Symbol.toStringTag]();
Expand Up @@ -18,5 +18,7 @@ extend1({
foo (n) {
return n.length + this.bar();
},
bar: ()=>14
bar () {
return 14;
}
});
Expand Up @@ -18,7 +18,9 @@ function implicitThis(n) {
let impl = {
a: 12,
explicitVoid2: ()=>this.a,
explicitVoid1: ()=>12,
explicitVoid1 () {
return 12;
},
explicitStructural () {
return this.a;
},
Expand Down
Expand Up @@ -80,7 +80,9 @@ let vue = new Vue({
return this.x;
},
hello: {
get: ()=>"hi",
get () {
return "hi";
},
set (value) {}
}
}
Expand Down
Expand Up @@ -7,9 +7,7 @@ class TextComponent extends React.Component {
}
_extends({}, {
editable: !1
});
let textPropsTrue = {
}), _extends({}, {
editable: !0,
onEdit () {}
};
_extends({}, textPropsTrue);
onEdit: ()=>{}
});

0 comments on commit 500c77d

Please sign in to comment.