File tree Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -10997,15 +10997,15 @@ namespace ts {
1099710997 // these partial properties when identifying discriminant properties, but otherwise they are filtered out
1099810998 // and do not appear to be present in the union type.
1099910999 function getUnionOrIntersectionProperty(type: UnionOrIntersectionType, name: __String, skipObjectFunctionPropertyAugment?: boolean): Symbol | undefined {
11000- const properties = skipObjectFunctionPropertyAugment ?
11001- type.propertyCacheWithoutObjectFunctionPropertyAugment ||= createSymbolTable( ) :
11002- type.propertyCache ||= createSymbolTable() ;
11003- let property = properties.get( name);
11004- if (! property) {
11005- property = createUnionOrIntersectionProperty(type, name, skipObjectFunctionPropertyAugment);
11006- if (property) {
11007- properties.set(name, property );
11008- }
11000+ let property = type.propertyCacheWithoutObjectFunctionPropertyAugment?.get(name) ||
11001+ !skipObjectFunctionPropertyAugment ? type.propertyCache?.get(name ) : undefined;
11002+ if (property) return property ;
11003+ property = createUnionOrIntersectionProperty(type, name, skipObjectFunctionPropertyAugment );
11004+ if (property) {
11005+ const properties = skipObjectFunctionPropertyAugment ?
11006+ type.propertyCacheWithoutObjectFunctionPropertyAugment ||= createSymbolTable() :
11007+ type.propertyCache ||= createSymbolTable( );
11008+ properties.set(name, property);
1100911009 }
1101011010 return property;
1101111011 }
You can’t perform that action at this time.
0 commit comments