18 रिपॉजिटरी
Mechanisms for mapping managed methods to native memory addresses so native libraries can trigger runtime logic.
Distinct from Functional Event Callbacks: Specifically about bridging managed methods as C-style function pointers, distinct from event-based callbacks in pure managed code.
Explore 18 awesome GitHub repositories matching programming languages & runtimes · Function-Pointer Callbacks. Refine with filters or upvote what's useful.
JSPatch is a JavaScript native bridge and method swizzler that allows for the dynamic injection of logic into a hosted native environment. It functions as a cross-language data mapper and execution engine, enabling the replacement of native function pointers with JavaScript wrappers to modify application behavior at runtime. The project provides the ability to perform runtime application patching by overriding native class methods and object properties. This allows for the modification of application logic and the application of hotfixes using JavaScript code loaded from local files or remote
Encapsulates JavaScript functions as native blocks to be executed as asynchronous callbacks by the host environment.
JNA is a foreign function interface and native memory mapper that allows Java applications to call functions in shared native libraries without writing custom JNI wrapper code. It serves as a JNI alternative framework for invoking C functions and mapping native data structures using high-level interfaces. The library distinguishes itself through its ability to translate Java objects and primitives into C-style structs, unions, and pointers for cross-platform memory exchange. On Windows, it provides a dedicated toolkit for interacting with Component Object Model objects using both early and la
Enables mapping Java methods to native function pointers, allowing external libraries to trigger logic within the JVM.
HybridCLR is a hybrid C# execution engine and assembly loader designed for Unity. It provides a system for hot-updating C# logic across all platforms at runtime without requiring the application to be rebuilt or reinstalled. The project is distinguished by its mixed-mode execution, which runs unmodified code at native speed while using a high-performance interpreter for updated functions. It includes a generic type resolver that allows hot-updated code to use generic classes and functions regardless of whether they were pre-instantiated in the main binary. To protect proprietary source code,
Facilitates high-speed data exchange between the managed runtime and native languages via a specialized bridge.
BlocksKit is a low-level utility library for Apple platform development, specifically designed for managing the execution flow and memory of blocks within macOS and iOS applications. It provides a collection of helper functions to simplify the use of blocks in Objective-C and C, reducing boilerplate code and addressing inherent technical limitations. The library focuses on bridging Objective-C blocks with legacy C-based APIs by providing compatible wrapper structures and function-pointer emulation. It enables the passing of blocks through system interfaces that require strict C-style callback
Maps block invocations to standard function pointers to satisfy strict type requirements in low-level system interfaces.
CXX is a code generator that produces a safe, zero-overhead FFI bridge between Rust and C++. It lets functions and data types from either language be used directly in the other, with static type safety enforced at compile time and no copying, serialization, or runtime checks across the boundary. The bridge supports the full range of cross-language interactions: Rust can call C++ functions and use C++ types, and C++ can call Rust functions and use Rust types. Standard library types like strings, vectors, and smart pointers are mapped automatically between the two languages, while opaque types
Transfers Rust closures as function pointers to C++ for callback-based event handling.
CppGuide is a curated collection of educational resources and practical guides focused on C++ server development, Linux kernel internals, concurrent programming, network protocols, and security exploitation. It provides structured learning paths for backend developers, covering everything from interview preparation to building high-performance network servers and understanding operating system fundamentals. The guide distinguishes itself by offering in-depth, hands-on tutorials that walk through real-world implementations, including building a Redis-like server from scratch, designing custom
Documents registering function pointers for decoupled coordination between kernel subsystems.
Carp is a statically typed Lisp compiler that compiles Lisp-like syntax directly to C source code, enabling seamless integration with existing C libraries and low-level system programming. It manages memory deterministically at compile time using ownership tracking and linear types, eliminating garbage collection pauses and runtime overhead while ensuring type safety through an inferred static type system. The language distinguishes itself through compile-time macro expansion and metaprogramming capabilities, allowing code generation and transformation before final binary output. It enforces
Provides a mechanism to obtain void pointers to functions for low-level interoperability.
sds एक C डायनामिक स्ट्रिंग लाइब्रेरी है जो हीप-एलोकेटेड स्ट्रिंग्स के लिए मेमोरी मैनेजमेंट रैपर प्रदान करती है। यह स्ट्रिंग की लंबाई को स्पष्ट रूप से ट्रैक करके बाइनरी-सेफ स्टोरेज लागू करती है, जिससे लाइब्रेरी डेटा के भीतर नल (null) कैरेक्टर को संभालने में सक्षम होती है। यह लाइब्रेरी एक ऐसी मेमोरी आर्किटेक्चर के माध्यम से खुद को अलग करती है जो एलोकेशन और फ्रीिंग के लिए इंटरचेंजेबल फंक्शन पॉइंटर्स का उपयोग करती है, जिससे कस्टम मेमोरी मैनेजरों का एकीकरण संभव हो जाता है। यह निरंतर-समय (constant-time) में लंबाई पुनर्प्राप्ति प्रदान करने के लिए हेडर-स्टोर्ड लेंथ ट्रैकिंग का उपयोग करती है और मानक C स्ट्रिंग फ़ंक्शंस के साथ संगतता सुनिश्चित करने के लिए नल-टर्मिनेटेड बफ़र पैडिंग बनाए रखती है। यह टूलकिट स्ट्रिंग हेरफेर (manipulation) क्षमताओं की एक विस्तृत श्रृंखला को कवर करती है, जिसमें कॉनकैटिनेशन, टोकनाइज़ेशन, जॉइनिंग और रेंज एक्सट्रैक्शन शामिल हैं। यह इन-प्लेस बफ़र म्यूटेशन के लिए उपयोगिताएँ भी प्रदान करती है, जैसे कि ट्रिमिंग और क्रॉपिंग, और इसमें मानक प्रिंट फ़ंक्शंस के लिए ऑप्टिमाइज़्ड स्ट्रिंग फ़ॉर्मेटिंग विकल्प शामिल हैं।
Provides interchangeable function pointers for allocation and freeing to enable custom memory managers.
Rhai एक एम्बेडेड स्क्रिप्टिंग इंजन और डायनामिकली टाइप्ड भाषा है जिसे Rust एप्लीकेशन्स में एकीकरण के लिए डिज़ाइन किया गया है। यह एक एब्सट्रैक्ट सिंटैक्स ट्री कंपाइलर और नेटिव इंटरऑप लेयर के रूप में कार्य करता है, जो डेवलपर्स को द्वि-दिशात्मक संचार के लिए Rust टाइप्स और फंक्शन्स को स्क्रिप्टिंग वातावरण में मैप करने की अनुमति देता है। यह प्रोजेक्ट अनुकूलन योग्य डोमेन-विशिष्ट भाषाएं बनाने के लिए एक फ्रेमवर्क के रूप में कार्य करता है। यह कस्टम ऑपरेटर्स, सिंटैक्स और प्रतिबंधित निष्पादन वातावरण की परिभाषा की अनुमति देता है, जिससे विशेष कार्यात्मक सेट के साथ विशिष्ट भाषाएं बनाना संभव हो जाता है। यह इंजन सुरक्षित निष्पादन के लिए रिसोर्स-कैप्ड सैंडबॉक्सिंग, मॉड्यूलर कोड ऑर्गनाइजेशन और न्यूमेरिक, स्ट्रिंग व बाइनरी टाइप्स के लिए व्यापक डेटा प्रोसेसिंग सहित क्षमताओं की एक विस्तृत श्रृंखला को कवर करता है। यह AST मैनिपुलेशन, निष्पादन स्थिति के सीरियलाइजेशन और कॉल स्टैक निरीक्षण व डिबगिंग इंटरफेस के माध्यम से रनटाइम ऑब्जर्वेबिलिटी के लिए भी उपकरण प्रदान करता है। यह इंजन नेटिव कंपाइलर द्वारा समर्थित किसी भी CPU या ऑपरेटिंग सिस्टम पर क्रॉस-प्लेटफॉर्म परिनियोजन के लिए डिज़ाइन किया गया है।
Provides mechanisms to map script-defined functions to native memory addresses so the host application can trigger runtime logic.
flutterrustbridge is a code generation tool that automatically creates type‑safe Dart bindings for Rust functions, enabling direct cross‑language calls between Flutter and a Rust backend. It provides an async FFI adapter that transforms synchronous Rust functions into Dart async methods with background thread management, a cross‑language object manager that wraps persistent Rust structs as Dart objects preserving state across calls, and trait object interop that converts Rust traits into Dart abstract classes for seamless bidirectional use. The project handles the full lifecycle of integrat
Enables Rust code to invoke Dart callbacks, supporting bidirectional communication between the two languages.
JavaCPP एक JNI C++ ब्रिज और फॉरेन फंक्शन इंटरफेस है जो एक बाइंडिंग जनरेटर, एक नेटिव लाइब्रेरी लोडर, और एक नेटिव मेमोरी मैनेजर प्रदान करता है। यह दोनों भाषाओं के बीच इंटरऑपरेबिलिटी को सक्षम करने के लिए नेटिव C++ हेडर्स और शेयर्ड लाइब्रेरीज़ के चारों ओर Java रैपर्स बनाने की प्रक्रिया को ऑटोमेट करता है। इस प्रोजेक्ट में एक C++ बाइंडिंग जनरेटर शामिल है जो नेटिव फंक्शन्स को कॉल करने के लिए आवश्यक ग्लू कोड और इंटरफेस को स्वचालित रूप से तैयार करने के लिए हेडर फाइलों को पार्स करता है। इसमें एक नेटिव लाइब्रेरी लोडर शामिल है जो रनटाइम एग्जीक्यूशन के लिए क्लासपाथ से प्लेटफॉर्म-विशिष्ट बाइनरीज को लोकल कैश में ढूंढता और निकालता है। यह सिस्टम मेमोरी लीक को रोकने के लिए डायरेक्ट पॉइंटर मैपिंग और रिसोर्स ट्रैकिंग के माध्यम से हाई-परफॉर्मेंस नेटिव मेमोरी एक्सेस को मैनेज करता है। यह C++ डेटा स्ट्रक्चर्स के लिए जटिल टाइप मैपिंग को संभालता है और फंक्शन पॉइंटर्स को Java मेथड्स से लिंक करने के लिए नेटिव कॉलबैक मैपिंग को सपोर्ट करता है। यह टूलसेट एग्जीक्यूशन समय को ऑप्टिमाइज़ करने और रिसोर्स ओवरहेड को कम करने के लिए मैनेज्ड मेथड्स को C++ या असेंबली इम्प्लीमेंटेशन के साथ बदलने की अनुमति देता है।
Links native function pointers or virtual functions to Java methods, allowing C++ code to trigger runtime logic.
Asterinas is a memory-safe operating system kernel designed to prevent data races and memory corruption. It functions as a Linux-ABI compatible kernel, enabling the execution of existing Linux binaries and container workloads while providing a declarative operating system distribution model. The project distinguishes itself by acting as a virtual machine container host and a confidential computing guest OS, allowing it to run within hardware-isolated Trusted Execution Environments such as Intel TDX. It implements a minimal trusted computing base by isolating unsafe low-level operations and se
Implements kernel-level callback registration for coordinating subsystems such as logging and power management.
Walt एक ट्रांसपाइलर और टाइप्ड भाषा है जो JavaScript-जैसे सिंटैक्स को WebAssembly बाइनरी फॉर्मेट में बदलती है। यह टाइप्ड सोर्स कोड को WebAssembly टेक्स्ट फॉर्मेट में अनुवादित करके ब्राउज़र और रनटाइम के लिए उच्च-प्रदर्शन तर्क विकसित करने के लिए एक टूलचेन के रूप में कार्य करता है। इस प्रोजेक्ट में एक बंडलर-एकीकृत लोडर शामिल है जो बिल्ड प्रक्रिया के दौरान सोर्स फाइलों के पुन: संकलन को स्वचालित करता है। यह एक लीनियर मेमोरी मैनेजर प्रदान करता है जिसका उपयोग एक सन्निहित हीप (contiguous heap) के भीतर कस्टम डेटा लेआउट, स्ट्रक्ट्स और मेमोरी एलोकेटर को परिभाषित करने के लिए किया जाता है। यह भाषा परिभाषित फंक्शन सिग्नेचर, न्यूमेरिक टाइप, और फंक्शन व ग्लोबल को एक्सपोर्ट करने या होस्ट वातावरण से बाहरी फंक्शन को इम्पोर्ट करने की क्षमता का सपोर्ट करती है। यह बाइनरी मेमोरी ऑफ़सेट के माध्यम से फंक्शनल क्लोजर, फंक्शन पॉइंटर्स और संरचित डेटा संगठन के उपयोग को सक्षम बनाती है।
Implements callbacks by mapping function references to indices within a WebAssembly table.
node-ffi is a foreign function interface library for Node.js that enables calling functions from native C dynamic libraries without writing manual C++ bindings. It serves as a system for loading shared objects and DLLs into process memory, translating JavaScript values into binary representations, and executing external binaries at runtime. The project utilizes a wrapper around the libffi library to construct call frames and execute native functions with dynamic arguments. It distinguishes itself by providing a native memory manager for allocating raw pointers and a mapping system that connec
Creates executable memory stubs that map JavaScript functions as C-style function pointers for native library callbacks.
libffi एक फॉरेन फ़ंक्शन इंटरफ़ेस लाइब्रेरी है जो रनटाइम पर अन्य भाषाओं में लिखे गए फ़ंक्शंस को कॉल करने में सक्षम बनाती है। यह एक मल्टी-आर्किटेक्चर ABI रैपर और डायनामिक कॉल फ़्रेम जनरेटर के रूप में कार्य करती है, जो तर्क प्रकारों (argument types) और रिटर्न मानों के रनटाइम विवरण के आधार पर बाहरी फ़ंक्शंस के निष्पादन की अनुमति देती है। यह प्रोजेक्ट विभिन्न हार्डवेयर आर्किटेक्चर और ऑपरेटिंग सिस्टम में विविध कॉलिंग कन्वेंशन को संभालने के लिए एक पोर्टेबल इंटरफ़ेस प्रदान करता है। इसमें एक्जीक्यूटेबल क्लोजर एलोकेशन की क्षमताएं शामिल हैं, जो फॉरेन कोड को एक्जीक्यूटेबल मेमोरी में संग्रहीत जंप टेबल के माध्यम से होस्ट भाषा के भीतर कॉलबैक ट्रिगर करने की अनुमति देती हैं। फ़ंक्शन इनवोकेशन के अलावा, यह लाइब्रेरी लो-लेवल असेंबली स्टब्स को मैनेज करती है और प्रकारों को रजिस्टर में मैप करने के ओवरहेड को कम करने के लिए कॉल प्लान कैशिंग का उपयोग करती है। इसमें विभिन्न लिंकर फॉर्मेट्स के बीच सिंबल-आधारित वर्ज़न स्क्रिप्ट को बदलने के लिए एक बाइनरी वर्ज़न स्क्रिप्ट कन्वर्टर भी शामिल है।
Creates executable closures that allow native libraries to trigger logic and functions within the host language.
uniffi-rs is a Rust FFI binding generator and multi-language binding tool. It functions as an automated binding scaffolder that creates type-safe foreign function interfaces and native wrappers for Rust libraries in languages such as Swift, Kotlin, and Python. The project provides a system for cross-language interface definition, allowing functions and data structures to be specified in a shared format to ensure consistent API signatures across platforms. It further serves as an FFI memory management layer, handling object lifetimes and thread safety when sharing state between Rust and foreig
Exports traits so foreign code can pass callback implementations into Rust functions.
Rusqlite is an embedded database interface and relational database driver that provides a client library for interacting with SQLite. It functions as an SQL query wrapper, enabling the management of local file-based or in-memory databases through a safe interface. The library allows for the extension of native database capabilities by implementing custom scalar functions, collations, and virtual tables. It also supports the embedding of the database engine directly into the application binary to remove external library dependencies. The project covers a broad range of capabilities including
Allows registering native application functions as callbacks that the database engine invokes during query execution.
Oils is a Unix shell interpreter and scripting language runtime that combines a modern shell language with POSIX and Bash compatibility. It functions as a structured data shell, integrating JSON and J8 formats to manage complex data without relying on string parsing. The system is distinguished by a C++ transpiled interpreter that converts a subset of Python source code into strongly typed C++ for high-performance execution. It features a garbage-collected typed runtime that supports prototype-based polymorphism, lexical closures, and reference-based variable mutation. To decouple shell logic
Provides the ability to send blocks of code as arguments to procedures for implementing callbacks.