Add expression functions with context boundaries
This commit is contained in:
parent
5085ae51aa
commit
773c34f3f4
18 changed files with 391 additions and 52 deletions
|
|
@ -8,6 +8,16 @@
|
|||
],
|
||||
"description": "Gotlin function"
|
||||
},
|
||||
"Expression Function": {
|
||||
"prefix": "exprfun",
|
||||
"body": ["fun ${1:name}(${2}) = ${3:expression}"],
|
||||
"description": "Gotlin expression-bodied function"
|
||||
},
|
||||
"With Go Context": {
|
||||
"prefix": "withcontext",
|
||||
"body": ["withContext(${1:request}.context()) {", " $0", "}"],
|
||||
"description": "Establish an ambient coroutine context from a Go context"
|
||||
},
|
||||
"Main Function": {
|
||||
"prefix": "main",
|
||||
"body": [
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue