Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for callPanic (0.18 sec)

  1. src/cmd/cgo/internal/test/callback_c_gccgo.c

    #include <stdint.h>
    #include <stdio.h>
    #include <stdlib.h>
    
    /* Test calling panic from C.  This is what SWIG does.  */
    
    extern void _cgo_panic(const char *);
    extern void *_cgo_allocate(size_t);
    
    void
    callPanic(void)
    {
    	_cgo_panic("panic from C");
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 12:00:02 UTC 2023
    - 452 bytes
    - Viewed (0)
  2. src/cmd/cgo/internal/test/callback_c_gc.c

    /* Test calling panic from C.  This is what SWIG does.  */
    
    extern void crosscall2(void (*fn)(void *, int), void *, int);
    extern void _cgo_panic(void *, int);
    extern void _cgo_allocate(void *, int);
    
    void
    callPanic(void)
    {
    	struct { const char *p; } a;
    	a.p = "panic from C";
    	crosscall2(_cgo_panic, &a, sizeof a);
    	*(int*)1 = 1;
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 12:00:02 UTC 2023
    - 592 bytes
    - Viewed (0)
  3. src/cmd/compile/internal/rangefunc/rewrite.go

    		Cond: r.cond(syntax.Neq, r.useObj(loop.stateVar), r.stateConst(abi.RF_READY)),
    		Then: &syntax.BlockStmt{
    			List: []syntax.Stmt{r.callPanic(start, r.useObj(loop.stateVar))},
    		},
    	}
    	setPos(nif, start)
    	return nif
    }
    
    func (r *rewriter) callPanic(start syntax.Pos, arg syntax.Expr) syntax.Stmt {
    	callPanicExpr := &syntax.CallExpr{
    		Fun:     runtimeSym(r.info, "panicrangestate"),
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:05:44 UTC 2024
    - 41.6K bytes
    - Viewed (0)
  4. src/cmd/cgo/internal/test/callback.go

    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package cgotest
    
    /*
    void callback(void *f);
    void callGoFoo(void);
    void callGoStackCheck(void);
    void callPanic(void);
    int callGoReturnVal(void);
    int returnAfterGrow(void);
    int returnAfterGrowFromGo(void);
    void callGoWithString(void);
    */
    import "C"
    
    import (
    	"path"
    	"runtime"
    	"strings"
    	"sync"
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri May 12 12:00:02 UTC 2023
    - 111.5K bytes
    - Viewed (0)
Back to top