@@ -3825,10 +3825,12 @@ let rec ResolvePartialLongIdentInModuleOrNamespace (ncenv: NameResolver) nenv is
38253825| id:: rest->
38263826
38273827( match mty.ModulesAndNamespacesByDemangledName.TryFind( id) with
3828- | Some mspec
3829- when not ( IsTyconUnseenObsoleteSpec ad g ncenv.amap m( modref.NestedTyconRef mspec) allowObsolete) ->
3830- let allowObsolete = rest<> [] && allowObsolete
3831- ResolvePartialLongIdentInModuleOrNamespace ncenv nenv isApplicableMeth m ad( modref.NestedTyconRef mspec) rest allowObsolete
3828+ | Some mspec->
3829+ let nested = modref.NestedTyconRef mspec
3830+ if IsTyconUnseenObsoleteSpec ad g ncenv.amap m nested allowObsoletethen [] else
3831+ let allowObsolete = allowObsolete&& not ( isNil rest)
3832+ ResolvePartialLongIdentInModuleOrNamespace ncenv nenv isApplicableMeth m ad nested rest allowObsolete
3833+
38323834| _ -> [])
38333835
38343836@ ( LookupTypeNameInEntityNoArity m id modref.ModuleOrNamespaceType
@@ -4009,19 +4011,21 @@ let rec ResolvePartialLongIdentInModuleOrNamespaceForRecordFields (ncenv: NameRe
40094011@ ( tycons|> List.map( modref.NestedTyconRef>> ItemOfTyconRef ncenv m) )
40104012@ [ // accessible record fields
40114013for tyconin tyconsdo
4012- if IsEntityAccessible ncenv.amap m ad( modref.NestedTyconRef tycon) then
4013- let ttype = FreshenTycon ncenv m( modref.NestedTyconRef tycon)
4014+ let nested = modref.NestedTyconRef tycon
4015+ if IsEntityAccessible ncenv.amap m ad nestedthen
4016+ let ttype = FreshenTycon ncenv m nested
40144017yield !
40154018 ncenv.InfoReader.GetRecordOrClassFieldsOfType( None, ad, m, ttype)
40164019|> List.map Item.RecdField
40174020]
40184021
40194022| id:: rest->
40204023( match mty.ModulesAndNamespacesByDemangledName.TryFind( id) with
4021- | Some mspec
4022- when not ( IsTyconUnseenObsoleteSpec ad g ncenv.amap m( modref.NestedTyconRef mspec) allowObsolete) ->
4023- let allowObsolete = rest<> [] && allowObsolete
4024- ResolvePartialLongIdentInModuleOrNamespaceForRecordFields ncenv nenv m ad( modref.NestedTyconRef mspec) rest allowObsolete
4024+ | Some mspec->
4025+ let nested = modref.NestedTyconRef mspec
4026+ if IsTyconUnseenObsoleteSpec ad g ncenv.amap m nested allowObsoletethen [] else
4027+ let allowObsolete = allowObsolete&& not ( isNil rest)
4028+ ResolvePartialLongIdentInModuleOrNamespaceForRecordFields ncenv nenv m ad nested rest allowObsolete
40254029| _ -> [])
40264030@ (
40274031match restwith
@@ -4395,16 +4399,18 @@ let rec ResolvePartialLongIdentInModuleOrNamespaceForItem (ncenv: NameResolver)
43954399|> List.filter( fun tcref -> not ( tcref.LogicalName.Contains( " ," )))
43964400|> List.filter( fun tycon -> not ( IsTyconUnseen ad g ncenv.amap m( modref.NestedTyconRef tycon)))
43974401
4398- // Get all the types and .NET constructor groups accessible from here
4399- yield ! tycons|> List.map( modref.NestedTyconRef>> ItemOfTyconRef ncenv m)
4400- yield ! tycons|> List.collect( modref.NestedTyconRef>> InfosForTyconConstructors ncenv m ad)
4402+ // Get all the types and .NET constructor groups accessible from here
4403+ let nestedTycons = tycons|> List.map modref.NestedTyconRef
4404+ yield ! nestedTycons|> List.map( ItemOfTyconRef ncenv m)
4405+ yield ! nestedTycons|> List.collect( InfosForTyconConstructors ncenv m ad)
44014406
44024407| id:: rest->
44034408
4404- match mty.ModulesAndNamespacesByDemangledName.TryFind( id) with
4405- | Some mspec
4406- when not ( IsTyconUnseenObsoleteSpec ad g ncenv.amap m( modref.NestedTyconRef mspec) true ) ->
4407- yield ! ResolvePartialLongIdentInModuleOrNamespaceForItem ncenv nenv m ad( modref.NestedTyconRef mspec) rest item
4409+ match mty.ModulesAndNamespacesByDemangledName.TryFind idwith
4410+ | Some mspec->
4411+ let nested = modref.NestedTyconRef mspec
4412+ if not ( IsTyconUnseenObsoleteSpec ad g ncenv.amap m nestedtrue ) then
4413+ yield ! ResolvePartialLongIdentInModuleOrNamespaceForItem ncenv nenv m ad nested rest item
44084414| _ -> ()
44094415
44104416for tyconin LookupTypeNameInEntityNoArity m id modref.ModuleOrNamespaceTypedo
@@ -4539,4 +4545,4 @@ let GetVisibleNamespacesAndModulesAtPoint (ncenv: NameResolver) (nenv: NameResol
45394545 IsInterestingModuleName demangledName&& notFakeContainerModule ilTyconNames demangledName
45404546&& EntityRefContainsSomethingAccessible ncenv m ad x
45414547&& not ( IsTyconUnseen ad ncenv.g ncenv.amap m x))
4542- )
4548+ )