- Sort Score
- Result 10 results
- Languages All
Results 51 - 60 of 80 for parenthesized (0.18 sec)
-
src/cmd/asm/internal/asm/parse.go
} // Constant. haveConstant := false switch tok.ScanToken { case scanner.Int, scanner.Float, scanner.String, scanner.Char, '+', '-', '~': haveConstant = true case '(': // Could be parenthesized expression or (R). Must be something, though. tok := p.next() if tok.ScanToken == scanner.EOF { p.errorf("missing right parenthesis") return } rname := tok.String() p.back()
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed Feb 21 14:34:57 UTC 2024 - 36.9K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/mod/modfile/read.go
} // An LParen represents the beginning of a parenthesized line block. // It is a place to store suffix comments. type LParen struct { Comments Pos Position } func (x *LParen) Span() (start, end Position) { return x.Pos, x.Pos.add(")") } // An RParen represents the end of a parenthesized line block. // It is a place to store whole-line (before) comments.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 03 02:38:00 UTC 2024 - 23.1K bytes - Viewed (0) -
src/cmd/compile/internal/syntax/parser.go
// *(T) p.syntaxError("cannot parenthesize embedded type") p.next() typ = p.qualifiedName(nil) p.got(_Rparen) // no need to complain if missing } else { // *T typ = p.qualifiedName(nil) } tag := p.oliteral() p.addField(styp, pos, nil, newIndirect(pos, typ), tag) case _Lparen: p.syntaxError("cannot parenthesize embedded type") p.next() var typ Expr
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 62.9K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/go/ast/astutil/enclosing.go
return "key/value association" case *ast.LabeledStmt: return "statement label" case *ast.MapType: return "map type" case *ast.Package: return "package" case *ast.ParenExpr: return "parenthesized " + NodeDescription(n.X) case *ast.RangeStmt: return "range loop" case *ast.ReturnStmt: return "return statement" case *ast.SelectStmt: return "select statement" case *ast.SelectorExpr:
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Dec 18 21:28:13 UTC 2023 - 15.9K bytes - Viewed (0) -
src/go/build/constraint/expr.go
p.lex() if p.tok == "!" { panic(&SyntaxError{Offset: p.pos, Err: "double negation not allowed"}) } return not(p.atom()) } return p.atom() } // atom parses a tag or a parenthesized expression. // On entry, the next input token HAS been lexed. // On exit, the next input token has been lexed and is in p.tok. func (p *exprParser) atom() Expr { // first token already in p.tok if p.tok == "(" {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Oct 19 12:02:03 UTC 2023 - 14.2K bytes - Viewed (0) -
src/go/parser/parser.go
x := &ast.BasicLit{ValuePos: p.pos, Kind: p.tok, Value: p.lit} p.next() return x case token.LPAREN: lparen := p.pos p.next() p.exprLev++ x := p.parseRhs() // types may be parenthesized: (some type) p.exprLev-- rparen := p.expect(token.RPAREN) return &ast.ParenExpr{Lparen: lparen, X: x, Rparen: rparen} case token.FUNC: return p.parseFuncTypeOrLit() }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Dec 08 20:07:50 UTC 2023 - 72.2K bytes - Viewed (0) -
src/cmd/compile/internal/types2/typexpr.go
return check.instantiatedType(e.X, syntax.UnpackListExpr(e.Index), def) case *syntax.ParenExpr: // Generic types must be instantiated before they can be used in any form. // Consequently, generic types cannot be parenthesized. return check.definedType(e.X, def) case *syntax.ArrayType: typ := new(Array) setDefType(def, typ) if e.Len != nil { typ.len = check.arrayLength(e.Len) } else { // [...]array
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 16.6K bytes - Viewed (0) -
src/go/types/typexpr.go
return check.instantiatedType(ix, def) case *ast.ParenExpr: // Generic types must be instantiated before they can be used in any form. // Consequently, generic types cannot be parenthesized. return check.definedType(e.X, def) case *ast.ArrayType: if e.Len == nil { typ := new(Slice) setDefType(def, typ) typ.elem = check.varType(e.Elt) return typ }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 16.3K bytes - Viewed (0) -
src/internal/types/testdata/check/typeparams.go
func identity[T any](x T) T { return x } func _[_ any](x int) int { panic(0) } func _[T any](T /* ERROR "redeclared" */ T)() {} func _[T, T /* ERROR "redeclared" */ any]() {} // Constraints (incl. any) may be parenthesized. func _[_ (any)]() {} func _[_ (interface{})]() {} func reverse[T any](list []T) []T { rlist := make([]T, len(list)) i := len(list) for _, x := range list { i--
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 19 01:56:58 UTC 2023 - 15.2K bytes - Viewed (0) -
src/go/printer/printer_test.go
_, err = parser.ParseFile(fset, "", got, 0) if err != nil { t.Errorf("%v\norig: %q\ngot : %q", err, src, got) } } // If a declaration has multiple specifications, a parenthesized // declaration must be printed even if Lparen is token.NoPos. func TestParenthesizedDecl(t *testing.T) { // a package with multiple specs in a single declaration const src = "package p; var ( a float64; b int )"
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Jun 03 14:56:25 UTC 2024 - 20.4K bytes - Viewed (0)