Sha256: b80c3e3f5e4887283a6e9d1c321089475d223ea808b65e6a508a7482f204c409

Contents?: true

Size: 1.57 KB

Versions: 158

Compression:

Stored size: 1.57 KB

Contents

/*
 * Copyright (c) 2009, 2010 Wayne Meissner
 * All rights reserved.
 *
 * This file is part of ruby-ffi.
 *
 * This code is free software: you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License version 3 only, as
 * published by the Free Software Foundation.
 *
 * This code is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License
 * version 3 for more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * version 3 along with this work.  If not, see <http://www.gnu.org/licenses/>.
 */

#ifndef RUBYFFI_CLOSUREPOOL_H
#define RUBYFFI_CLOSUREPOOL_H

typedef struct ClosurePool_ ClosurePool;
typedef struct Closure_ Closure;

struct Closure_ {
    void* info;      /* opaque handle for storing closure-instance specific data */
    void* function;  /* closure-instance specific function, called by custom trampoline */
    void* code;      /* The native trampoline code location */
    struct ClosurePool_* pool;
    Closure* next;
};

void rbffi_ClosurePool_Init(VALUE module);

ClosurePool* rbffi_ClosurePool_New(int closureSize, 
        bool (*prep)(void* ctx, void *code, Closure* closure, char* errbuf, size_t errbufsize),
        void* ctx);

void rbffi_ClosurePool_Free(ClosurePool *);

Closure* rbffi_Closure_Alloc(ClosurePool *);
void rbffi_Closure_Free(Closure *);

void* rbffi_Closure_GetCodeAddress(Closure *);

#endif /* RUBYFFI_CLOSUREPOOL_H */

Version data entries

158 entries across 158 versions & 13 rubygems

Version Path
ffi-1.1.0-x86-mingw32 ext/ffi_c/ClosurePool.h
ffi-1.1.0 ext/ffi_c/ClosurePool.h
classiccms-0.4.2 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.4.1 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.4.0 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.3.9 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
sunrise-cms-0.3.3 vendor/bundle/ruby/1.9.1/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
sunrise-cms-0.3.2 vendor/bundle/ruby/1.9.1/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
sunrise-cms-0.3.1 vendor/bundle/ruby/1.9.1/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
sunrise-cms-0.3.0 vendor/bundle/ruby/1.9.1/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.3.8 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.3.7 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.3.6 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.3.5 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.3.4 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.3.3 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.3.2 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.3.1 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
classiccms-0.3.0 vendor/bundle/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h
sunrise-cms-0.3.0.rc vendor/bundle/ruby/1.9.1/gems/ffi-1.0.11/ext/ffi_c/ClosurePool.h