-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Open
Labels
Breaking ChangeWould introduce errors in existing codeWould introduce errors in existing codeEffort: ModerateRequires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual".Requires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual".Help WantedYou can do thisYou can do thisSuggestionAn idea for TypeScriptAn idea for TypeScript
Milestone
Description
TypeScript Version:
1.8.X
Code
class FooBase {
private static privateStatic: string = "";
testBase(): void {
console.log(FooBase.privateStatic);
// Should error, but doesn't
console.log(Foo.privateStatic);
}
}
class Foo extends FooBase {
test() {
// Should error, and does
console.log(Foo.privateStatic);
}
}
Expected behavior:
Accessing Foo.privateStatic
shouldn't be allowed, regardless of the context it's called in.
Actual behavior:
FooBase
is allowed to do this.
(thanks @sethbrenith for deducing this)
burdiuz
Metadata
Metadata
Assignees
Labels
Breaking ChangeWould introduce errors in existing codeWould introduce errors in existing codeEffort: ModerateRequires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual".Requires experience with the TypeScript codebase, but feasible. Harder than "Effort: Casual".Help WantedYou can do thisYou can do thisSuggestionAn idea for TypeScriptAn idea for TypeScript