mirror of
https://github.com/swc-project/swc.git
synced 2024-12-26 15:12:08 +03:00
26 lines
367 B
TypeScript
26 lines
367 B
TypeScript
// @allowJs: true
|
|
// @checkJs: true
|
|
// @noEmit: true
|
|
// @Filename: test.js
|
|
|
|
function f(x) {}
|
|
f(); // Always been ok
|
|
|
|
class C {
|
|
static m(x) {}
|
|
p = x => {}
|
|
m(x) {}
|
|
}
|
|
|
|
C.m(); // Always been ok
|
|
new C().m(); // Regression #39261
|
|
new C().p(); // Regression #39261
|
|
|
|
const obj = {
|
|
m(x) {},
|
|
p: x => {}
|
|
};
|
|
|
|
obj.m(); // Always been ok
|
|
obj.p(); // Always been ok
|