How elhamdolillah/ilm-al-kitab works
MAL is an Arabic-oriented programming language with compiler front ends and native code-generation paths. The main documented workflow is a user invoking malc to check, compile, or run a source file; a separate malc-native tool lowers input to NIR and compiles native output. The tree also contains mathematical and language-feature libraries. The README is empty, and excerpts are partial, so several subsystem connections are intentionally left unspecified.
Main entry points: src/main.rs malc CLI · src/main.rs malc-native · server.py Flask server · lib.rs Native codegen
Components 20
Compiler interfaces
- malc CLI
MAL/src/cli/src/main.rs - Flask server
server.py - malc-native
MAL/tools/malc-native/src/main.rs
Compilation pipeline
- Lexer
MAL/src/lexer/src/lib.rs - Parser
MAL/src/parser/src/lib.rs - AST arena
MAL/src/arena/src/lib.rs - Type inference
MAL/src/nir/src/type_inference.rs - NIR lowering
MAL/src/nir/src/lowering.rs - C backend
MAL/src/backend/src/lib.rs - Native codegen
MAL/src/native/src/lib.rs
Mathematical libraries
- Proof search
MAL/src/search/src/lib.rs - Model theory
MAL/src/model/src/lib.rs - Set theory
MAL/src/set/src/lib.rs - Category theory
MAL/src/category/src/lib.rs
Language features
- Abjad types
MAL/src/abjad/src/lib.rs - Knowledge base
MAL/src/kb/src/lib.rs - Sessions
MAL/src/session/src/lib.rs
Other components
- Program author
- MAL source
- Native binary
Connections 11
- Program author → malc CLI: invokes
- malc CLI → MAL source: reads
- malc CLI → C backend: transpiles
- malc CLI → Native binary: writes
- malc-native → MAL source: reads
- malc-native → AST arena: allocates
- malc-native → NIR lowering: lowers AST
- malc-native → Native codegen: compiles NIR
- Native codegen → Native binary: emits ELF
- Flask server → malc CLI: runs compiler
- Flask server → Native binary: executes