mirror of
https://github.com/swc-project/swc.git
synced 2024-12-24 06:05:02 +03:00
29 lines
344 B
TypeScript
29 lines
344 B
TypeScript
function foo(x) { return x; }
|
|
var f = function foo(x) { return x; }
|
|
var f2 = (x) => x;
|
|
var f3 = <T>(x) => x;
|
|
|
|
class C {
|
|
foo(x) {
|
|
return x;
|
|
}
|
|
}
|
|
|
|
interface I {
|
|
foo(x);
|
|
foo2(x, y);
|
|
}
|
|
|
|
var a: {
|
|
foo(x);
|
|
}
|
|
|
|
var b = {
|
|
foo(x) {
|
|
return x;
|
|
},
|
|
a: function foo(x) {
|
|
return x;
|
|
},
|
|
b: (x) => x
|
|
} |