Skip to content
This repository has been archived by the owner on Jul 15, 2023. It is now read-only.

Commit

Permalink
Changed swapped $2 and $0 position for anonymous go function snippet. (
Browse files Browse the repository at this point in the history
…#2354)

For anonymous go function (the snippet with the prefix "go") I think it will be more convenient if we end snippets in the body instead of the variable field. The function body is the largest of these 3 placeholders and will be in need of completion features more than any other. Therefore, I think, it is reasonable if we give it the $0 place.
  • Loading branch information
uroybd authored and jhendrixMSFT committed Mar 5, 2019
1 parent fa94793 commit 238a473
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion snippets/go.json
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@
},
"goroutine anonymous function": {
"prefix": "go",
"body": "go func($1) {\n\t$2\n}($0)",
"body": "go func($1) {\n\t$0\n}($2)",
"description": "Snippet for anonymous goroutine declaration"
},
"goroutine function": {
Expand Down

0 comments on commit 238a473

Please sign in to comment.