New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AddUnimportedPackages: true overwrites file header on autoimport #904

Closed
logrusorgru opened this Issue Jan 9, 2019 · 1 comment

Comments

Projects
None yet
2 participants
@logrusorgru
Copy link

logrusorgru commented Jan 9, 2019

Automatic import overwrites file head.

// Configure general auto-completion behaviour
&golang.MarGocodeCtl{
	// ...
	AddUnimportedPackages: true,
	// ...
},

gosublime_autoimport_overwriting_x4

logrusorgru added a commit to logrusorgru/GoSublime that referenced this issue Jan 12, 2019

logrusorgru added a commit to logrusorgru/GoSublime that referenced this issue Jan 12, 2019

DisposaBoy added a commit that referenced this issue Jan 12, 2019

@DisposaBoy

This comment has been minimized.

Copy link
Owner

DisposaBoy commented Jan 12, 2019

There's still at least one more edge-case left, but the main issue should be fixed now.

DisposaBoy added a commit to DisposaBoy/margo that referenced this issue Jan 19, 2019

Use a code-generation strategy instead of modifying the AST when addi…
…ng imports.

The latter is a too unreliable when there are comments involved.
This should fix DisposaBoy/GoSublime#904 completely.

DisposaBoy added a commit to KurokuLabs/margo that referenced this issue Jan 19, 2019

Use a code-generation strategy instead of modifying the AST when addi…
…ng imports. (#100)

The latter is a too unreliable when there are comments involved.
This should fix DisposaBoy/GoSublime#904 completely.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment