Stream: t-compiler/wg-rls-2.0

Topic: dot completions with subfields

Coenen Benjamin (May 05 2020 at 13:25, on Zulip):

Hello @matklad I'm currently thinking about add subfields for dot autocompletion. For example if I have this kind of struct

struct A {
      b: B,

struct B {
     my_number: usize

// autocomplete
let my_struct_a = A{...};

let my_number = my_struct_a.<|>

// and then it lists autocompletions for b.my_number
// I think to put a depth of 3 to have some kind of a.b.c completion.

In GoPLS they provide this kind of completion and it's often pretty useful. Do you think it could be a good idea ?

matklad (May 05 2020 at 13:26, on Zulip):

Yeah, I think we should do smart completion eventually, but probably not right now

matklad (May 05 2020 at 13:26, on Zulip):

The pre-requsite is having robust and correct ordering implemented

matklad (May 05 2020 at 13:27, on Zulip):

we don't have that yet. Adding smart variants if some of the dumb variants are wrog/wrongly orderd could be a net negative

Coenen Benjamin (May 05 2020 at 13:32, on Zulip):

Ok thanks :) BTW I answered to this issue maybe I don't understand something.

Last update: Sep 22 2020 at 01:45UTC