Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for PanicCallback (0.17 sec)

  1. src/runtime/testdata/testprogcgo/panic.go

    // We want to test unwinding from a cgo callback.
    
    /*
    void call_callback(void);
    */
    import "C"
    
    func init() {
    	register("PanicCallback", PanicCallback)
    }
    
    //export panic_callback
    func panic_callback() {
    	var i *int
    	*i = 42
    }
    
    func PanicCallback() {
    	C.call_callback()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Oct 27 20:29:07 UTC 2021
    - 312 bytes
    - Viewed (0)
  2. src/runtime/crash_cgo_test.go

    	t.Parallel()
    	got := runTestProg(t, "testprogcgo", "PanicCallback")
    	t.Log(got)
    	want := "panic: runtime error: invalid memory address or nil pointer dereference"
    	if !strings.Contains(got, want) {
    		t.Errorf("did not see %q in output", want)
    	}
    	want = "panic_callback"
    	if !strings.Contains(got, want) {
    		t.Errorf("did not see %q in output", want)
    	}
    	want = "PanicCallback"
    	if !strings.Contains(got, want) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Apr 15 16:44:47 UTC 2024
    - 22.2K bytes
    - Viewed (1)
Back to top