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

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions