Skip to content

autocomplete gives wrong completion on dot on generic type #4966

Description

@smoothdeveloper
type Foo = FooValue of int
  with
  member x.Value = match x with | FooValue v -> v

type Data<'t>(d: 't) =
  member x.Data = d

let a = [|FooValue 1;FooValue 2|] |> Array.map Data

a.[0].Data.  // try autcomplete after the dot
((FooValue 1) |> Data).Data. // note that here it works

I'd expect being able to complete after the dot, it should show Value member and other members from System.Object.

When I'm not accessing the value from an indexer, it somehow works.

Environment: VS2017, does the same in ionide as well

Metadata

Metadata

Assignees

No one assigned

    Labels

    Area-LangService-AutoCompleteautocomplete/intellisenseBugImpact-Low(Internal MS Team use only) Describes an issue with limited impact on existing code.

    Type

    No fields configured for Bug.

    Projects

    Status
    New

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions