| 79 | } |
| 80 | |
| 81 | class Static { |
| 82 | static #p: number |
| 83 | static #q: number |
| 84 | #r: number |
| 85 | m(): number { |
| 86 | Static.#p = 2; |
| 87 | if (Static.#p === 3) { // Refinements still work |
| 88 | (Static.#p : 3); |
| 89 | } |
| 90 | return Static.#p; |
| 91 | } |
| 92 | bad() { |
| 93 | IncompatibleGetAndSet.#q; // Error, not visible here |
| 94 | Static.#q = Static.#p; |
| 95 | this.#p = 3; // Error, no #p on instance |
| 96 | this.#q; // Error, no #q on instance |
| 97 | Static.#r; // Error, no #r on class |
| 98 | Static.#r = Static.#q; // Error, no #r on class |
| 99 | } |
| 100 | } |
| 101 | |
| 102 | class Annotations { |
| 103 | // Private class fields must either be annotated or have an initializer |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…