Commit 9e3571f
authored
fix(isolated-declarations): private accessors keep their types (oxc-project#9132)
Input:
```ts
export class Cls {
accessor d: string;
private accessor e: string;
private static accessor f: string;
}
```
Expected:
```ts
export declare class Cls {
accessor d: string;
private accessor e;
private static accessor f;
}
```
Actual:
```ts
export declare class Cls {
accessor d: string;
private accessor e: string;
private static accessor f: string;
}
```
ts playground:
https://www.typescriptlang.org/play/?#code/MYGwhgzhAEDCIwN4ChrTMYBTKB7ATtACYBc0EALvgJYB2A5gNyrQAONAbmBVupjhALQsZSjQbM07alx7kK3asD7Y8hAGaiqdJsgC+yZEA1 parent 19fdf89 commit 9e3571f
File tree
3 files changed
+17
-5
lines changed- crates/oxc_isolated_declarations
- src
- tests
- fixtures
- snapshots
3 files changed
+17
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
504 | 504 | | |
505 | 505 | | |
506 | 506 | | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
507 | 512 | | |
508 | 513 | | |
509 | 514 | | |
| |||
514 | 519 | | |
515 | 520 | | |
516 | 521 | | |
517 | | - | |
| 522 | + | |
518 | 523 | | |
519 | 524 | | |
520 | 525 | | |
| |||
Lines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
17 | 21 | | |
18 | 22 | | |
19 | 23 | | |
| |||
Lines changed: 7 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
15 | 18 | | |
16 | 19 | | |
17 | 20 | | |
| |||
23 | 26 | | |
24 | 27 | | |
25 | 28 | | |
26 | | - | |
27 | | - | |
28 | | - | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
29 | 32 | | |
30 | | - | |
| 33 | + | |
31 | 34 | | |
32 | 35 | | |
33 | 36 | | |
| |||
0 commit comments