fix: remove accessibility of constructor (#10658)
This commit is contained in:
parent
0f949990c3
commit
2640e5a27c
@ -93,6 +93,7 @@ export default declare(
|
||||
// Rest handled by Function visitor
|
||||
},
|
||||
constructor(path, classPath) {
|
||||
if (path.node.accessibility) path.node.accessibility = null;
|
||||
// Collects parameter properties so that we can add an assignment
|
||||
// for each of them in the constructor body
|
||||
//
|
||||
|
||||
@ -1,4 +1,5 @@
|
||||
class C {
|
||||
m(): void;
|
||||
public m(x?: number, ...y: number[]): void {}
|
||||
public constructor() {}
|
||||
}
|
||||
|
||||
@ -1,4 +1,6 @@
|
||||
class C {
|
||||
m(x, ...y) {}
|
||||
|
||||
constructor() {}
|
||||
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user