- Sort Score
- Result 10 results
- Languages All
Results 161 - 170 of 1,675 for mypanic (0.23 sec)
-
test/fixedbugs/bug119.go
return a[0] // this seems to do the wrong thing } func main() { a := &[]int{12} if x := (*a)[0]; x != 12 { panic(2) } if x := foo(*a); x != 12 { // fails (x is incorrect) panic(3) } } /* uetli:~/Source/go1/test/bugs gri$ 6go bug119 3 70160 panic on line 83 PC=0x14d6 0x14d6?zi mainĀ·main(23659, 0, 1, ...) mainĀ·main(0x5c6b, 0x1, 0x7fff5fbff830, ...) 0x52bb?zi
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Sat Feb 18 21:15:42 UTC 2012 - 697 bytes - Viewed (0) -
test/func8.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 02 13:43:18 UTC 2016 - 599 bytes - Viewed (0) -
test/closure4.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Aug 14 09:19:38 UTC 2018 - 364 bytes - Viewed (0) -
test/fixedbugs/bug012.go
var u31 uint64 = 1; _, _ = u30, u31; var u32 uint64 = 18446744073709551615; var u33 uint64 = +18446744073709551615; if u32 != (1<<64)-1 { panic("u32\n"); } if u33 != (1<<64)-1 { panic("u33\n"); } var i34 int64 = ^0; // note: 2's complement means ^0 == -1 if i34 != -1 { panic("i34") } } /* bug12.go:5: overflow converting constant to <uint64>UINT64 bug12.go:6: overflow converting constant to <uint64>UINT64
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Feb 17 04:48:57 UTC 2012 - 756 bytes - Viewed (0) -
test/fixedbugs/issue9537.dir/b.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Jan 22 03:25:12 UTC 2015 - 678 bytes - Viewed (0) -
src/cmd/cgo/internal/testlife/life_test.go
GOPATH, err := os.MkdirTemp("", "cgolife") if err != nil { log.Panic(err) } defer os.RemoveAll(GOPATH) os.Setenv("GOPATH", GOPATH) // Copy testdata into GOPATH/src/cgolife, along with a go.mod file // declaring the same path. modRoot := filepath.Join(GOPATH, "src", "cgolife") if err := cgotest.OverlayDir(modRoot, "testdata"); err != nil { log.Panic(err) } if err := os.Chdir(modRoot); err != nil { log.Panic(err)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon May 22 20:56:09 UTC 2023 - 1.5K bytes - Viewed (0) -
test/fixedbugs/issue23837.go
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Oct 30 17:45:19 UTC 2018 - 1.1K bytes - Viewed (0) -
internal/dsync/drwmutex_test.go
t.Fatalf("unlock of unlocked RWMutex did not panic") } }() mu := NewDRWMutex(ds, "test") mu.Unlock(context.Background()) } // Borrowed from rwmutex_test.go func TestUnlockPanic2(t *testing.T) { mu := NewDRWMutex(ds, "test-unlock-panic-2") defer func() { if recover() == nil { t.Fatalf("unlock of unlocked RWMutex did not panic") }
Registered: Sun Jun 16 00:44:34 UTC 2024 - Last Modified: Sat Dec 24 03:49:07 UTC 2022 - 9.7K bytes - Viewed (0) -
test/fixedbugs/bug070.go
import "fmt" func main() { var i, k int var r string outer: for k = 0; k < 2; k++ { r += fmt.Sprintln("outer loop top k", k) if k != 0 { panic("k not zero") } // inner loop breaks this one every time for i = 0; i < 2; i++ { if i != 0 { panic("i not zero") } // loop breaks every time r += fmt.Sprintln("inner loop top i", i) if true { r += "do break\n" break outer } } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri Feb 17 04:49:30 UTC 2012 - 715 bytes - Viewed (0) -
test/typeparam/issue47258.go
x++ return x } func main() { if got, want := inc(int32(5)), int32(6); got != want { panic(fmt.Sprintf("got %d, want %d", got, want)) } if got, want := inc(float64(5)), float64(6.0); got != want { panic(fmt.Sprintf("got %d, want %d", got, want)) } if got, want := inc(complex64(5)), complex64(6.0); got != want { panic(fmt.Sprintf("got %d, want %d", got, want)) }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Mar 01 19:45:34 UTC 2022 - 686 bytes - Viewed (0)