-
Notifications
You must be signed in to change notification settings - Fork 17.8k
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
x/tools/gopls: completion for f.Fuzz
parameter
#51089
Comments
Change https://go.dev/cl/385974 mentions this issue: |
Change https://go.dev/cl/387615 mentions this issue: |
In test files, function definitions starting with Test, Bench, or Fuzz can be completed almost automatically. For the snippets the user hits tab, completes the name, hits tab again, and the function is defined, except (of course) for its body. Otherwise a completion that fills in the signature is proposed. Where appropriate, 'TestMain(m *testing.M)' is also offered as a completion. Fixes golang/go#46896 and golang/go#51089 Change-Id: I46c05af0ead79c1d82ca40b2c605045e06e1a35d Reviewed-on: https://go-review.googlesource.com/c/tools/+/385974 Run-TryBot: Peter Weinberger <[email protected]> Trust: Peter Weinberger <[email protected]> TryBot-Result: Gopher Robot <[email protected]> gopls-CI: kokoro <[email protected]> Reviewed-by: Hyang-Ah Hana Kim <[email protected]>
Reopening, as I don't think this feature is quite working correctly. If I am inside a fuzz function and type |
I cannot reproduce this. Inside a FuzzFoo func, after typing a call to
f.Add, when I type f.F I get a oompletion, and if I keep typing I keep
getting the completion.
(If there hasn't been a call to f.Add, then there's no f.Fuzz completion.
Is that the problem?
…On Tue, Mar 15, 2022 at 2:33 PM findleyr ***@***.***> wrote:
Reopening, as I don't think this feature is quite working correctly.
If I am inside a fuzz function and type f.Fuz, the current implementation
drops the completion to Fuzz. I think that's a bug -- it should only
prune completions inside of a fuzz *target*.
—
Reply to this email directly, view it on GitHub
<#51089 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABJIAIYGT52ZQB4TX2Z2PB3VADJXDANCNFSM5N32ZHNA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you were assigned.Message ID:
***@***.***>
|
closed by 393019 |
Going one step further from #50198
It would be nice if gopls fills out the parameter automatically based on
f.Add
if it is present.The text was updated successfully, but these errors were encountered: