File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11{{/* This is a template for Promises */ -}}
2- // This is auto generated code
2+ // Package async contains promise implementations generated for specific types.
3+ // This is auto generated code.
34package async
45
56import (
@@ -11,11 +12,10 @@ import (
1112 {{- end }}
1213)
1314
14- // Promise represents an eventual completion of an ansynchronous operation
15- // and its resulting value. Promise can be either fulfilled or failed and
16- // it can happen only one time. All Promise operations are thread-safe.
17- //
18- // To create a promise use: ` &{{ .Prefix }}Promise{}`
15+ // {{ .Prefix }}Promise represents an eventual completion of an ansynchronous
16+ // operation and its resulting value. Promise can be either fulfilled or
17+ // failed and it can happen only one time. All Promise operations are
18+ // thread-safe. To create a promise use: ` &{{ .Prefix }}Promise{}`
1919type {{ .Prefix }}Promise struct {
2020 mutex sync.Mutex
2121 successFn func({{ .Type }})
Original file line number Diff line number Diff line change @@ -2,7 +2,8 @@ package main
22
33// promiseTemplateContent contains the template string from promise.go.tmpl
44var promiseTemplateContent = `{{/* This is a template for Promises */ -}}
5- // This is auto generated code
5+ // Package async contains promise implementations generated for specific types.
6+ // This is auto generated code.
67package async
78
89import (
@@ -14,11 +15,10 @@ import (
1415 {{- end }}
1516)
1617
17- // Promise represents an eventual completion of an ansynchronous operation
18- // and its resulting value. Promise can be either fulfilled or failed and
19- // it can happen only one time. All Promise operations are thread-safe.
20- //
21- // To create a promise use: ` + "`" + `&{{ .Prefix }}Promise{}` + "`" + `
18+ // {{ .Prefix }}Promise represents an eventual completion of an ansynchronous
19+ // operation and its resulting value. Promise can be either fulfilled or
20+ // failed and it can happen only one time. All Promise operations are
21+ // thread-safe. To create a promise use: ` + "`" + `&{{ .Prefix }}Promise{}` + "`" + `
2222type {{ .Prefix }}Promise struct {
2323 mutex sync.Mutex
2424 successFn func({{ .Type }})
You can’t perform that action at this time.
0 commit comments