From e31aa9e12ae98fe5cbfffdd4aaee85bf0b67197b Mon Sep 17 00:00:00 2001 From: Sheetal Nandi Date: Wed, 6 Aug 2014 11:26:34 -0700 Subject: [PATCH] Added more comments and todos as per code review feedback --- src/compiler/checker.ts | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/compiler/checker.ts b/src/compiler/checker.ts index 378e23bf83d..076478ae989 100644 --- a/src/compiler/checker.ts +++ b/src/compiler/checker.ts @@ -711,6 +711,20 @@ module ts { return { accessibility: SymbolAccessibility.Accessible }; } + // TODO(shkamat): Handle static method of class + + // If we havent got the accessible symbol doesnt mean the symbol is actually inaccessible. + // It could be qualified symbol and hence verify the path + // eg: + // module m { + // export class c { + // } + // } + // var x: typeof m.c + // In the above example when we start with checking if typeof m.c symbol is accessible, + // we are going to see if c can be accessed in scope directly. + // But it cant, hence the accessible is going to be undefined, but that doesnt mean m.c is accessible + // It is accessible if the parent m is accessible because then m.c can be accessed through qualification meaningToLook = SymbolFlags.Namespace; symbol = symbol.parent; }