Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 141 for comment1 (0.17 sec)

  1. src/go/printer/printer_test.go

    	comment := f.Comments[0].List[0]
    	pos := comment.Pos()
    	if fset.PositionFor(pos, false /* absolute position */).Offset != 1 {
    		t.Error("expected offset 1") // error in test
    	}
    
    	testComment(t, f, len(src), &ast.Comment{Slash: pos, Text: "//-style comment"})
    	testComment(t, f, len(src), &ast.Comment{Slash: pos, Text: "/*-style comment */"})
    	testComment(t, f, len(src), &ast.Comment{Slash: pos, Text: "/*-style \n comment */"})
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 03 14:56:25 UTC 2024
    - 20.4K bytes
    - Viewed (0)
  2. src/cmd/vendor/golang.org/x/tools/go/analysis/passes/directive/directive.go

    	for _, group := range f.Comments {
    		// A //go:build or a //go:debug comment is ignored after the package declaration
    		// (but adjoining it is OK, in contrast to +build comments).
    		if group.Pos() >= f.Package {
    			check.inHeader = false
    		}
    
    		// Check each line of a //-comment.
    		for _, c := range group.List {
    			check.comment(c.Slash, c.Text)
    		}
    	}
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 04 16:19:04 UTC 2024
    - 5.4K bytes
    - Viewed (0)
  3. cni/pkg/ipset/nldeps_linux.go

    	if ipsetErr, ok := err.(nl.IPSetError); ok && ipsetErr == nl.IPSET_ERR_EXIST {
    		return nil
    	}
    
    	return err
    }
    
    func (m *realDeps) destroySet(name string) error {
    	err := netlink.IpsetDestroy(name)
    	return err
    }
    
    func (m *realDeps) addIP(name string, ip netip.Addr, ipProto uint8, comment string, replace bool) error {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu May 30 18:07:05 UTC 2024
    - 3.9K bytes
    - Viewed (0)
  4. src/go/build/build.go

    		comment, _, ok = bytes.Cut(data[2:], starSlash)
    		if !ok {
    			// malformed comment
    			return "", 0
    		}
    		if bytes.Contains(comment, newline) {
    			return "", 0
    		}
    	}
    	comment = bytes.TrimSpace(comment)
    
    	// split comment into `import`, `"pkg"`
    	word, arg := parseWord(comment)
    	if string(word) != "import" {
    		return "", 0
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 16:25:21 UTC 2024
    - 62.3K bytes
    - Viewed (0)
  5. src/go/build/read.go

    	for _, group := range info.parsed.Comments {
    		if group.Pos() >= info.parsed.Package {
    			break
    		}
    		for _, c := range group.List {
    			if strings.HasPrefix(c.Text, "//go:") {
    				info.directives = append(info.directives, Directive{c.Text, info.fset.Position(c.Slash)})
    			}
    		}
    	}
    
    	// If the file imports "embed",
    	// we have to look for //go:embed comments
    	// in the remainder of the file.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed May 29 16:25:21 UTC 2024
    - 14.1K bytes
    - Viewed (0)
  6. src/cmd/compile/internal/types2/stdlib_test.go

    		// get per-file instructions
    		expectErrors := false
    		filename := filepath.Join(path, f.Name())
    		goVersion := ""
    		if comment := firstComment(filename); comment != "" {
    			if strings.Contains(comment, "-goexperiment") {
    				continue // ignore this file
    			}
    			fields := strings.Fields(comment)
    			switch fields[0] {
    			case "skip", "compiledir":
    				continue // ignore this file
    			case "errorcheck":
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 30 19:18:33 UTC 2024
    - 13.3K bytes
    - Viewed (0)
  7. doc/README.md

    The `initial` and `next` subdirectories of this directory are for release notes.
    
    ## For developers
    
    Release notes should be added to `next` by editing existing files or creating
    new files. **Do not add RELNOTE=yes comments in CLs.** Instead, add a file to
    the CL (or ask the author to do so).
    
    At the end of the development cycle, the files will be merged by being
    concatenated in sorted order by pathname. Files in the directory matching the
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jun 05 19:56:43 UTC 2024
    - 3.1K bytes
    - Viewed (0)
  8. pkg/kubelet/network/dns/dns_test.go

    		{"\t\n\t", []string{}, []string{}, []string{}, false},
    		{"#comment\n", []string{}, []string{}, []string{}, false},
    		{" #comment\n", []string{}, []string{}, []string{}, false},
    		{"#comment\n#comment", []string{}, []string{}, []string{}, false},
    		{"#comment\nnameserver", []string{}, []string{}, []string{}, true},                           // nameserver empty
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 04 06:25:43 UTC 2024
    - 25.6K bytes
    - Viewed (0)
  9. pkg/util/coverage/fake_test_deps.go

    //nolint:unused // U1000 see comment above, we know it's unused normally.
    func (fakeTestDeps) StartCPUProfile(io.Writer) error {
    	return nil
    }
    
    //nolint:unused // U1000 see comment above, we know it's unused normally.
    func (fakeTestDeps) StopCPUProfile() {}
    
    //nolint:unused // U1000 see comment above, we know it's unused normally.
    func (fakeTestDeps) StartTestLog(io.Writer) {}
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 29 15:31:22 UTC 2024
    - 3.5K bytes
    - Viewed (0)
  10. src/cmd/go/internal/help/helpdoc.go

    A package statement is said to have an "import comment" if it is immediately
    followed (before the next newline) by a comment of one of these two forms:
    
    	package math // import "path"
    	package math /* import "path" */
    
    The go command will refuse to install a package with an import comment
    unless it is being referred to by that import path. In this way, import comments
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 11 16:54:28 UTC 2024
    - 36.3K bytes
    - Viewed (0)
Back to top