anchor.diff:                      let plid, residue = List.frontAndBack origLongIdent
                       plid, Some residue
   
  -            let envItems, ty = GetEnvironmentLookupResolutions(mkPos line loc, plid, filterCtors, residueOpt.IsSome)
  -            
  +            let (nenv, ad), m = GetBestEnvForPos (mkPos line loc)
  +            let ty = NameResolution.TryToResolveLongIdentAsType ncenv nenv m plid
  +
               match nameResItems with            
               | NameResResult.TypecheckStaleAndTextChanged -> None // second-chance intellisense will try again
               | NameResResult.Cancel(denv,m) -> Some([], denv, m)
  
positive.code: 
          // Completion at 'inherit C(...)"
          | Some (CompletionContext.Inherit(InheritanceContext.Class, (plid, _))) ->
              GetEnvironmentLookupResolutions(mkPos line loc, plid, filterCtors, false)
              |> fst
              |> FilterRelevantItemsBy None GetBaseClassCandidates
              |> Option.map toCompletionItems
  
          // Completion at 'interface ..."
          | Some (CompletionContext.Inherit(InheritanceContext.Interface, (plid, _))) ->
              GetEnvironmentLookupResolutions(mkPos line loc, plid, filterCtors, false)
              |> fst
              |> FilterRelevantItemsBy None GetInterfaceCandidates
              |> Option.map toCompletionItems
  
          // Completion at 'implement ..."
          | Some (CompletionContext.Inherit(InheritanceContext.Unknown, (plid, _))) ->
              GetEnvironmentLookupResolutions(mkPos line loc, plid, filterCtors, false) 
              |> fst
              |> FilterRelevantItemsBy None (fun t -> GetBaseClassCandidates t || GetInterfaceCandidates t)
              |> Option.map toCompletionItems
  
  
negative.code:                         None
                      | _ ->         
                         // Use an environment lookup as the last resort
                         let envItems = GetEnvironmentLookupResolutions(nenv, ad, m, plid, filterCtors, residueOpt.IsSome)
                         match nameResItems, envItems, qualItems with            
                         
                         // First, use unfiltered name resolution items, if they're not empty
  