Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 53 for badexit (0.12 sec)

  1. src/cmd/go/testdata/script/cover_build_simple.txt

    go tool covdata percent -i=data/goodexit
    stdout  'coverage:.*[1-9][0-9.]+%'
    
    # Program makes a direct call to os.Exit(1).
    env GOCOVERDIR=data/badexit
    ! exec ./example.exe badexit
    ! stderr '^warning: GOCOVERDIR not set, no coverage data emitted'
    go tool covdata percent -i=data/badexit
    stdout  'coverage:.*[1-9][0-9.]+%'
    
    # Program invokes panic.
    env GOCOVERDIR=data/panic
    ! exec ./example.exe panic
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 28 11:50:58 UTC 2022
    - 3.1K bytes
    - Viewed (0)
  2. src/runtime/ehooks_test.go

    			expected string
    			musthave []string
    		}{
    			{
    				mode:     "simple",
    				expected: "bar foo",
    			},
    			{
    				mode:     "goodexit",
    				expected: "orange apple",
    			},
    			{
    				mode:     "badexit",
    				expected: "blub blix",
    			},
    			{
    				mode: "panics",
    				musthave: []string{
    					"fatal error: exit hook invoked panic",
    					"main.testPanics",
    				},
    			},
    			{
    				mode: "callsexit",
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 24 16:41:13 UTC 2024
    - 2.1K bytes
    - Viewed (0)
  3. src/runtime/testdata/testexithooks/testexithooks.go

    	_ "unsafe"
    )
    
    var modeflag = flag.String("mode", "", "mode to run in")
    
    func main() {
    	flag.Parse()
    	switch *modeflag {
    	case "simple":
    		testSimple()
    	case "goodexit":
    		testGoodExit()
    	case "badexit":
    		testBadExit()
    	case "panics":
    		testPanics()
    	case "callsexit":
    		testHookCallsExit()
    	case "exit2":
    		testExit2()
    	default:
    		panic("unknown mode")
    	}
    }
    
    func testSimple() {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 24 16:41:13 UTC 2024
    - 2.1K bytes
    - Viewed (0)
  4. src/cmd/go/testdata/script/test_badtest.txt

    ! go test badtest/badexec
    ! stdout ^ok
    stdout ^FAIL\tbadtest/badexec
    
    ! go test badtest/badsyntax
    ! stdout ^ok
    stdout ^FAIL\tbadtest/badsyntax
    
    ! go test badtest/badvar
    ! stdout ^ok
    stdout ^FAIL\tbadtest/badvar
    
    ! go test notest
    ! stdout ^ok
    stderr '^notest.hello.go:6:1: syntax error: non-declaration statement outside function body' # Exercise issue #7108
    
    -- badtest/badexec/x_test.go --
    package badexec
    
    func init() {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jan 06 15:47:54 UTC 2020
    - 805 bytes
    - Viewed (0)
  5. src/cmd/go/testdata/script/mod_go_version_missing.txt

    # module or a bad-script-edited 1.16 module.
    
    ! go list -mod=vendor all
    ! stderr '^go: inconsistent vendoring'
    stderr 'cannot find module providing package example.com/badedit: import lookup disabled by -mod=vendor'
    
    # When we set -mod=mod, the go version should be updated immediately,
    # to the current version, converting the requirements from eager to lazy.
    #
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Feb 22 16:11:33 UTC 2023
    - 3.1K bytes
    - Viewed (0)
  6. src/cmd/go/testdata/script/env_unset.txt

    # Test that we can unset variables, even if initially invalid,
    # as long as resulting config is valid.
    
    env GOENV=badenv
    env GOOS=
    env GOARCH=
    env GOEXPERIMENT=
    
    ! go env
    stderr '^go(\.exe)?: unknown GOEXPERIMENT badexp$'
    
    go env -u GOEXPERIMENT
    
    ! go env
    stderr '^go: unsupported GOOS/GOARCH pair bados/badarch$'
    
    ! go env -u GOOS
    stderr '^go: unsupported GOOS/GOARCH pair \w+/badarch$'
    
    ! go env -u GOARCH
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 15 00:06:54 UTC 2021
    - 553 bytes
    - Viewed (0)
  7. src/cmd/link/internal/ld/util.go

    package ld
    
    import (
    	"cmd/link/internal/loader"
    	"encoding/binary"
    	"fmt"
    	"os"
    )
    
    var atExitFuncs []func()
    
    func AtExit(f func()) {
    	atExitFuncs = append(atExitFuncs, f)
    }
    
    // runAtExitFuncs runs the queued set of AtExit functions.
    func runAtExitFuncs() {
    	for i := len(atExitFuncs) - 1; i >= 0; i-- {
    		atExitFuncs[i]()
    	}
    	atExitFuncs = nil
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Feb 22 20:39:11 UTC 2023
    - 2.5K bytes
    - Viewed (0)
  8. src/go/printer/testdata/parser.go

    		// TODO determine a better range for BadExpr below
    		par.List = []*ast.Field{{Type: &ast.BadExpr{pos, pos}}}
    		return par
    	}
    
    	// recv type must be of the form ["*"] identifier
    	recv := par.List[0]
    	base := deref(recv.Type)
    	if _, isIdent := base.(*ast.Ident); !isIdent {
    		p.errorExpected(base.Pos(), "(unqualified) identifier")
    		par.List = []*ast.Field{{Type: &ast.BadExpr{recv.Pos(), recv.End()}}}
    	}
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Jul 20 20:19:51 UTC 2023
    - 50.5K bytes
    - Viewed (0)
  9. src/cmd/covdata/covdata.go

    var memprofilerateflag = flag.Int("memprofilerate", 0, "Set memprofile sampling rate to value")
    
    var matchpkg func(name string) bool
    
    var atExitFuncs []func()
    
    func atExit(f func()) {
    	atExitFuncs = append(atExitFuncs, f)
    }
    
    func Exit(code int) {
    	for i := len(atExitFuncs) - 1; i >= 0; i-- {
    		f := atExitFuncs[i]
    		atExitFuncs = atExitFuncs[:i]
    		f()
    	}
    	os.Exit(code)
    }
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 19:41:17 UTC 2024
    - 5.7K bytes
    - Viewed (0)
  10. build-logic/binary-compatibility/src/test/kotlin/gradlebuild/binarycompatibility/KotlinInternalFilteringTest.kt

            internal val bar = "bar"
    
            internal var bazar = "bazar"
    
            internal fun String.fooExt() {}
    
            internal fun Int.fooExt() {}
    
            internal val String.barExt: String
                get() = "bar"
    
            internal var Int.bazarExt: String
                get() = "bar"
                set(value) = Unit
    
        """
    
        private
        val publicMembers = """
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue Jul 11 06:57:51 UTC 2023
    - 6.2K bytes
    - Viewed (0)
Back to top