百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
A

alan

> 编程语言
开源

自动扩展的编程语言

322 stars0 点赞0 次浏览
访问官网GitHub

工具介绍

自动扩展的编程语言

Documentation for Alan v0.2. Looking for v0.1 documentation? Visit the legacy documentation.

** WORK IN PROGRESS** - The core of the language is functional, but parts of the standard library and package management are still unfinished.

** Predictable runtime for all computations** - A program is represented as DAG(s) where the running time for all computations can be predicted because there is no unbounded recursion or iteration.

⛓ Transparent GPGPU programming - Alan's restrictions on recursion and iteration allows for automatic generation of compute shaders for your code. (Not yet implemented)

✅ Almost no runtime errors - No deadlocks, livelocks, undefined variables, divide-by-zero, integer under/overflow, array out-of-bounds access, etc. Due to the type system and the standard library primitives provided to you.

⚡️ Native performance with Rust - Alan's new compiler transforms your code into Rust before finally generating a binary for your platform, without needing to worry about memory management or GC pauses by handling Rust's borrow checker for you.


‍ Alan is a programming language that makes the power of the GPU more accessible, with a syntax similar to a dynamic language (it's typed, but 100% inferred), and restrictions on recursion and iteration to make automatic generation of multi-threaded CPU and GPGPU versions of your code for you.

Installation

Currently, the only way to install alan is to have a working rust development environment along with git to clone this repo and install it manually:

bash
git clone https://github.com/alantech/alan
cd alan
cargo install --path alan

alan v0.2 has been tested on x86-64 for Windows, Mac, and Linux, ARM64 for Linux and Mac, and RISC-V for Linux.

Usage

To compile, simply:

alan compile .ln

This will create a file with the name `` that you can run (or error if it fails to compile).

Contribution

Source Installation:

If you wish to contribute to Alan, you'll need a development environment to build Alan locally:

  • git (any recent version should work)
  • Rust >=1.92.0
  • Node.js >=22.0.0 and pnpm (the compiler falls back to yarn or npm if pnpm is unavailable)
  • A complete C toolchain (gcc, clang, msvc)

Once those are installed, clone the repo and work from the monorepo root (the directory that contains alan/, alan_compiler/, etc.):

bash
git clone https://github.com/alantech/alan
cd alan
cargo install --path alan   # install the `alan` CLI binary

To build without installing, or to run tests during development:

bash
cargo build -p alan
cargo test --release

Use --release for tests: debug builds have much larger stack frames and can false-positive stack overflow in parser depth-limit tests.

Unit and Integration Tests:

The tests are included within the Rust source files. Test coverage is not yet 100%, with the majority of unit tests in the src/parse.rs file defining the Alan syntax parser. The unit tests directly follow the functions they test, instead of all being at the end as is standard in Rust, because it seemed easier to read that way. These tests all pass.

Beyond that are integration tests in the src/compile.rs file, making up the vast majority of that file (which for release is just a single function that is a small wrapper around the transpilation code in lntors.rs). Few of these tests currently pass, as they were inherited from the Alan v0.1 test suite. Most are planned for revival but some may be changed or dropped.

License

MIT

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

Rustalanparallelizationprogramming-language

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月18日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言