github.com/gnolang/gno@v0.0.0-20240520182011-228e9d0192ce/gnovm/tests/files/method27.gno (about) 1 package main 2 3 import ( 4 "fmt" 5 6 "github.com/gnolang/gno/_test/net/http" 7 ) 8 9 type AuthenticatedRequest struct { 10 http.Request 11 Username string 12 } 13 14 func main() { 15 a := &AuthenticatedRequest{} 16 fmt.Println("ua:", a.UserAgent()) 17 } 18 19 // Output: 20 // ua: