16 lines
169 B
JavaScript
16 lines
169 B
JavaScript
|
/**
|
||
|
* @flow
|
||
|
*/
|
||
|
|
||
|
class Foo {
|
||
|
_method(): string {
|
||
|
return 'this is private';
|
||
|
}
|
||
|
}
|
||
|
|
||
|
class Bar extends Foo {
|
||
|
test() {
|
||
|
(this._method(): string); // error
|
||
|
}
|
||
|
}
|