- Sort Score
- Result 10 results
- Languages All
Results 31 - 40 of 78 for Tok (0.04 sec)
-
src/go/types/return.go
if call, ok := ast.Unparen(s.X).(*ast.CallExpr); ok && check.isPanic[call] { return true } case *ast.ReturnStmt: return true case *ast.BranchStmt: if s.Tok == token.GOTO || s.Tok == token.FALLTHROUGH { return true } case *ast.BlockStmt: return check.isTerminatingList(s.List, "") case *ast.IfStmt: if s.Else != nil && check.isTerminating(s.Body, "") &&
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Feb 22 19:32:17 UTC 2024 - 4.2K bytes - Viewed (0) -
src/go/types/stmt.go
return } op := assignOp(s.Tok) if op == token.ILLEGAL { check.errorf(atPos(s.TokPos), InvalidSyntaxTree, "unknown assignment operation %s", s.Tok) return } var x operand check.binary(&x, nil, s.Lhs[0], s.Rhs[0], op, s.TokPos) if x.mode == invalid { return } check.assignVar(s.Lhs[0], nil, &x, "assignment") } case *ast.GoStmt:
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 19:19:55 UTC 2024 - 30.6K bytes - Viewed (0) -
src/encoding/xml/read.go
// or more fields have the path to this element as a parent // prefix. Recurse and attempt to match these. for { var tok Token tok, err = d.Token() if err != nil { return true, err } switch t := tok.(type) { case StartElement: // the recursion depth of unmarshalPath is limited to the path length specified
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Sep 08 19:04:28 UTC 2023 - 22.4K bytes - Viewed (0) -
src/go/printer/printer.go
// use that information to decide more directly. needsLinebreak := false if p.mode&noExtraBlank == 0 && last.Text[1] == '*' && p.lineFor(last.Pos()) == next.Line && tok != token.COMMA && (tok != token.RPAREN || p.prevOpen == token.LPAREN) && (tok != token.RBRACK || p.prevOpen == token.LBRACK) { if p.containsLinebreak() && p.mode&noExtraLinebreak == 0 && p.level == 0 { needsLinebreak = true } else {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Oct 19 12:02:03 UTC 2023 - 41.6K bytes - Viewed (0) -
src/go/ast/ast.go
IncDecStmt struct { X Expr TokPos token.Pos // position of Tok Tok token.Token // INC or DEC } // An AssignStmt node represents an assignment or // a short variable declaration. // AssignStmt struct { Lhs []Expr TokPos token.Pos // position of Tok Tok token.Token // assignment token, DEFINE Rhs []Expr }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 28 21:32:41 UTC 2024 - 35.6K bytes - Viewed (0) -
src/go/parser/resolver.go
r.declare(n, nil, r.labelScope, ast.Lbl, n.Label) ast.Walk(r, n.Stmt) case *ast.AssignStmt: r.walkExprs(n.Rhs) if n.Tok == token.DEFINE { r.shortVarDecl(n) } else { r.walkExprs(n.Lhs) } case *ast.BranchStmt: // add to list of unresolved targets if n.Tok != token.FALLTHROUGH && n.Label != nil { depth := len(r.targetStack) - 1 r.targetStack[depth] = append(r.targetStack[depth], n.Label)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Nov 02 12:56:53 UTC 2023 - 15.8K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/go/analysis/passes/shift/shift.go
checkLongShift(pass, node, node.X, node.Y) } case *ast.AssignStmt: if len(node.Lhs) != 1 || len(node.Rhs) != 1 { return } if node.Tok == token.SHL_ASSIGN || node.Tok == token.SHR_ASSIGN { checkLongShift(pass, node, node.Lhs[0], node.Rhs[0]) } } }) return nil, nil } // checkLongShift checks if shift or shift-assign operations shift by more than
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 02:20:05 UTC 2024 - 3.5K bytes - Viewed (0) -
src/go/token/example_test.go
relPosition := fset.Position(pos) absPosition := fset.PositionFor(pos, false) // Either a FuncDecl or GenDecl, since we exit on error. kind := "func" if gen, ok := decl.(*ast.GenDecl); ok { kind = gen.Tok.String() } // If the relative and absolute positions differ, show both. fmtPosition := relPosition.String() if relPosition != absPosition { fmtPosition += "[" + absPosition.String() + "]" }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Oct 09 22:09:31 UTC 2023 - 1.7K bytes - Viewed (0) -
src/go/printer/nodes.go
// Files func declToken(decl ast.Decl) (tok token.Token) { tok = token.ILLEGAL switch d := decl.(type) { case *ast.GenDecl: tok = d.Tok case *ast.FuncDecl: tok = token.FUNC } return } func (p *printer) declList(list []ast.Decl) { tok := token.ILLEGAL for _, d := range list { prev := tok tok = declToken(d)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Oct 17 18:53:17 UTC 2023 - 52.6K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/go/analysis/passes/copylock/copylock.go
// might inadvertently copy a lock by checking whether // any of the range variables are locks. func checkCopyLocksRange(pass *analysis.Pass, r *ast.RangeStmt) { checkCopyLocksRangeVar(pass, r.Tok, r.Key) checkCopyLocksRangeVar(pass, r.Tok, r.Value) } func checkCopyLocksRangeVar(pass *analysis.Pass, rtok token.Token, e ast.Expr) { if e == nil { return } id, isId := e.(*ast.Ident) if isId && id.Name == "_" {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Jun 04 16:19:04 UTC 2024 - 9.9K bytes - Viewed (0)