mirror of
https://github.com/SourceFellows/gobuch.git
synced 2026-07-03 19:37:06 +02:00
initial import
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
)
|
||||
|
||||
type contextKey string
|
||||
|
||||
func main() {
|
||||
var key contextKey = "test"
|
||||
ctx := context.Background()
|
||||
ctx = context.WithValue(ctx, key, "world")
|
||||
fmt.Println(ctx.Value(key))
|
||||
}
|
||||
Reference in New Issue
Block a user