29 repository-uri
Programming constructs that allow functions to retain access to variables from their outer lexical scope after execution.
Explore 29 awesome GitHub repositories matching software engineering & architecture · Closures. Refine with filters or upvote what's useful.
Acest proiect este o serie educațională cuprinzătoare, concepută pentru a oferi o înțelegere tehnică profundă a limbajului de programare JavaScript. Acesta funcționează ca un curriculum multi-volum care ghidează dezvoltatorii prin mecanismele de bază, modelele de execuție și specificațiile subiacente care definesc modul în care limbajul operează la un nivel fundamental. Curriculumul se distinge prin concentrarea pe arhitectura internă a limbajului, mai degrabă decât pe sintaxa de suprafață. Acesta oferă o analiză riguroasă a unor subiecte complexe, cum ar fi lexical scope, încapsularea stării bazată pe closure, moștenirea bazată pe prototype și mecanica event loop-ului. Explorând modul în care motorul gestionează contextele de execuție și mediile variabile, seria permite dezvoltatorilor să navigheze prin nuanțele sistemelor de tip dinamic și ale coerciției implicite cu o predictibilitate mai mare. Materialul acoperă întregul spectru al fundamentelor limbajului, inclusiv modele orientate pe obiecte, fluxuri de execuție asincronă și regulile gramaticale care guvernează transformarea datelor. Aceste resurse sunt structurate pentru a ajuta practicienii să treacă de la utilizarea de bază la stăpânirea mecanismelor interne ale limbajului, susținând în final dezvoltarea unui software mai ușor de întreținut și mai eficient. Conținutul este disponibil sub formă de serie de manuale tehnice și ghiduri conceptuale destinate studiului sistematic.
Illustrates the mechanics of lexical scoping and how functions maintain access to outer variables after execution.
Rust is a programming language designed for memory safety and performance. It provides a comprehensive curriculum that covers fundamental syntax, memory management, and advanced programming paradigms, including support for functional and object-oriented styles. The language features a strong type system that enforces memory safety through ownership, borrowing, and lifetime annotations, while also offering mechanisms for handling both recoverable and unrecoverable errors. The language includes extensive support for concurrent programming, providing primitives for thread management, shared-stat
Retains access to outer lexical scope variables within functions using trait-based return types.
Ruby is a general-purpose, dynamic programming language built on an object-oriented runtime environment. It treats every piece of data as an object, ensuring a consistent interface for manipulation across the entire system. The language is designed to support programmer productivity through a focus on natural syntax and flexible metaprogramming capabilities. The runtime distinguishes itself through a pure object model that allows for dynamic class modification and runtime method definition. It supports functional programming patterns by encapsulating code blocks as objects that capture their
Encapsulates code blocks as objects that capture lexical scope to enable functional programming patterns.
The Rust Programming Language Book is the official technical guide and educational resource for the Rust language. It provides a comprehensive walkthrough of the language's design, focusing on its core identity as a systems programming language that enforces memory safety and high-performance execution without the need for a garbage collector. The project is distinguished by its focus on ownership, borrowing, and lifetime tracking, which allow the compiler to verify memory safety and thread safety at compile time. It covers the language's unique approach to zero-cost abstractions, including t
Returns closures from functions using trait syntax or boxed trait objects to enable dynamic behavior.
This project is a comprehensive technical interview preparation resource and computer science interview guide. It serves as an educational reference for developers to study core software engineering fundamentals and common coding patterns required for employment screenings. The repository provides detailed guides and references covering data structures and algorithms, networking and security, operating systems, and web development. It specifically focuses on the implementation and complexity analysis of sorting, searching, and graph algorithms. The material encompasses a wide breadth of comp
Describes how closures maintain access to lexical environments and outer scopes.
node-lessons is a comprehensive Node.js programming course and instructional guide. It provides a collection of guided lessons and code examples designed to teach the fundamentals of the Node.js runtime and server-side JavaScript development. The project serves as a practical guide for building web servers and backend applications, specifically covering the implementation of HTTP servers, request routing, and middleware chains. It includes specialized instructional material on managing asynchronous JavaScript workflows through promises and flow control, as well as guides for integrating NoSQL
Covers the implementation of closures to retain access to variables from an outer lexical scope.
This library provides a collection of reusable hooks designed to manage state, side effects, and browser interactions within React applications. It functions as a toolkit for handling asynchronous data fetching and complex component logic, offering a set of type-safe utilities that reduce boilerplate code and improve maintainability. The library distinguishes itself through its focus on isomorphic lifecycle synchronization, ensuring consistent behavior across client and server environments to prevent hydration mismatches. It employs ref-based closure stabilization to ensure that asynchronous
Wraps functions to ensure asynchronous callbacks always access the most recent state values.
WebViewJavascriptBridge is a communication layer for sending bidirectional messages between native Objective-C code and JavaScript within iOS and macOS web views. It serves as an interoperability toolkit for synchronizing data and executing callbacks between native Apple platform applications and their embedded web content. The project provides a messaging interface that exposes native functions to the web environment and triggers JavaScript handlers from native application code. It enables the registration of named handlers in native code that can be invoked by JavaScript to request device a
Enables triggering specific JavaScript handlers within the web view and capturing return values via native callbacks.
wasm-bindgen is a glue code generator and interoperability tool that facilitates high-level communication and data exchange between compiled Rust modules and JavaScript environments. It functions as a memory bridge and type definition generator, allowing the exchange of complex data types and the calling of functions across execution boundaries. The project distinguishes itself by automating the conversion of data types and function signatures using attribute-based bindings. It generates the necessary JavaScript and WebAssembly wrappers to manage linear memory mapping and creates automatic Ty
Wraps internal Rust closures for use in the host environment with options for ownership transfer.
Aspects is an aspect-oriented programming library and method hooking framework designed for intercepting and modifying JavaScript function behavior without altering the original source code. It serves as a runtime logic injector that allows for the addition and removal of executable code wrappers from active functions. The library enables the injection of custom logic before or after methods to change application behavior at runtime. It further provides the ability to intercept method calls to capture or override return values before they reach the caller. The framework manages these interce
Implements a stack of intercepted call wrappers using JavaScript closures to maintain original function references.
This project is an interactive programming education resource and tutorial designed for learning the Rust programming language and systems programming concepts. It provides a collection of runnable and editable code examples that serve as a practical reference for language syntax and implementation. The resource features an interactive code sandbox that allows users to execute and test code snippets in real time. It emphasizes the verification of technical accuracy by executing embedded code blocks during the build process to ensure all examples remain functional. The content covers a compre
Demonstrates how to pass closures into functions using trait bounds for flexible logic execution.
100 Go Mistakes is a reference book and code review companion that catalogues frequent Go programming anti-patterns and provides corrected implementations for each one. It covers a wide range of common pitfalls, from range loop variable capture and interface nil handling to error wrapping and map iteration randomization, helping developers recognize and avoid these issues in their own code. The project distinguishes itself by offering a structured, example-driven approach to learning idiomatic Go. It covers core design decisions such as when to use pointer versus value receivers, how to apply
Explains how to avoid immediate argument evaluation in Go defer statements.
miniblink49 is a stripped-down Blink browser kernel and embedded web UI framework used to integrate HTML user interfaces into native C++ applications. It functions as a C++ JavaScript interop bridge that maps high-level script calls to low-level native logic and provides a resource-optimized headless browser engine for processing web content without a graphical interface. The project enables custom browser environment control by bypassing cross-origin security policies to allow requests across different domains. It further allows for the interception of network resources to replace remote ass
Creates JavaScript functions backed by native C++ logic through member pointers and callbacks.
This project is a comprehensive Lisp AI implementation library that provides reference implementations for various artificial intelligence paradigms and symbolic algorithms. It functions as a multi-purpose toolkit containing a logic programming engine, a natural language processing suite, and a symbolic mathematics toolkit. The library is distinguished by its diverse architectural frameworks, including a Prolog-style execution engine that uses unification and goal-driven backtracking, and a system for simulating human decision-making through expert system shells and certainty factors. It also
Implements functions that capture and maintain access to variables from their defining lexical environment.
This project is a comprehensive frontend interview preparation resource built around a question bank of over 1000 curated questions. It covers HTML, CSS, JavaScript, Vue, React, Node, TypeScript, Webpack, algorithms, and network security, with each question accompanied by a detailed answer explanation. The content is organized into a hierarchical category tree for browsable exploration, and a daily question rotation algorithm presents one question per day for systematic review. A client-side search index enables instant filtering of questions by title or tag, and the entire question bank is p
Provides exercises for creating closures that retain access to outer scope variables, enabling private data and persistent state.
The Rust RFCs repository is the formal home for the Rust language evolution process, housing the structured design documents and community review mechanisms that govern changes to the Rust programming language, its compiler, and its standard library. It defines the complete lifecycle for proposing, discussing, and implementing substantial changes through RFC documents, from initial submission and community feedback through final comment periods and sub-team sign-offs. The repository codifies the governance and collaboration processes that shape Rust's development, including mechanisms for com
Defines the automatic coercion from function items to closure types, a key part of Rust's type system.
CodeIgniter is a PHP web framework built on the Model-View-Controller pattern, designed for building full-stack web applications. It provides a lightweight toolkit with minimal configuration, organizing application logic into controllers, models, and views for clean separation of concerns. The framework includes a fluent query builder for constructing SQL statements programmatically, PSR-4 autoloading with namespace mapping, and a service-based dependency injection container for managing shared class instances. The framework distinguishes itself through its comprehensive set of built-in tools
Provides the ability to use closures as direct route handlers without a controller class.
MockK is a Kotlin test double framework that creates mocks, spies, and relaxed mocks for unit testing, with support for final classes, static methods, and coroutines. It functions as a bytecode instrumentation library that modifies compiled class files at load time to intercept constructors, final methods, and static functions without source changes, and also provides dedicated libraries for constructor mocking and coroutine mocking. The framework is designed specifically for Kotlin, handling Kotlin-specific constructs like extension functions, singletons, and suspend functions. MockK disting
Records actual arguments passed to stubbed methods into typed slots for later inspection and assertion in test code.
mQuickjs is a compact JavaScript engine designed for memory-constrained devices, such as microcontrollers, requiring as little as 10 KB of RAM and 100 KB of ROM. It achieves this through a fixed-buffer memory allocation scheme that avoids system heap usage, a compacting tracing garbage collector that eliminates fragmentation, and a ROM-embedded standard library that reduces both memory footprint and startup time. The engine compiles JavaScript source into portable bytecode that can be stored in persistent memory and executed without reparsing, and it emulates IEEE 754 floating-point arithmetic
Exposes native C functions as JavaScript closures with captured parameters, callable from script code in embedded environments.
Rhai este un motor de scripting încorporat și un limbaj cu tipizare dinamică, conceput pentru integrarea în aplicații Rust. Acesta funcționează ca un compilator de arbore sintactic abstract (AST) și un strat de interop nativ, permițând dezvoltatorilor să mapeze tipuri și funcții Rust într-un mediu de scripting pentru comunicare bidirecțională. Proiectul servește drept framework pentru crearea de limbaje specifice domeniului (DSL) personalizabile. Permite definirea de operatori, sintaxă și medii de execuție restricționate, facilitând crearea de limbaje specializate cu seturi funcționale adaptate. Motorul acoperă o gamă largă de capabilități, inclusiv sandboxing cu resurse limitate pentru execuție securizată, organizare modulară a codului și procesare cuprinzătoare de date pentru tipuri numerice, string-uri și binare. Oferă, de asemenea, instrumente pentru manipularea AST, serializarea stării de execuție și observabilitate la runtime prin inspectarea stivei de apeluri și interfețe de debugging. Motorul este conceput pentru deployment cross-platform pe orice CPU sau sistem de operare suportat de compilatorul nativ.
Creates script-accessible function pointers that trigger native host functions or closures.