Skip to content

Add LSP struct literal snippet completion after Type. #134

Description

@itsfuad

Goal

Standalone, deferred LSP completion feature for current Type.{...} syntax.

After Type., offer a struct literal completion for .{required fields} with editable tab stops. Applied edit must produce Type.{...} without duplicating the already typed dot.

Requirements

  • Preserve existing member completions alongside the struct literal candidate.
  • Honor client snippet support; do not send snippet placeholders to clients without support.
  • Emit required fields in declaration order and follow existing field default/required-field rules; do not invent new default semantics.
  • Add completion and applied-edit tests covering tab stops, existing member candidates, clients with/without snippet support, declaration order, and defaulted fields.

Separate from auto-import operation completion (#74). This feature has no syntax-migration prerequisite.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Relationships

None yet

Development

No branches or pull requests

Issue actions