frut_lib

Crates.iofrut_lib
lib.rsfrut_lib
version0.0.4
created_at2025-10-01 16:43:04.979219+00
updated_at2025-11-06 10:51:50.673125+00
descriptionA no_std library for parsing, analyzing, and executing the Frut programming language.
homepage
repositoryhttps://github.com/BenimFurka/frut_lib
max_upload_size
id1862951
size219,750
furka (BenimFurka)

documentation

README

Frut Library

Crates.io Documentation License

A no_std library for parsing, analyzing, and executing the Frut programming language. This library provides the core functionality for lexing, parsing, semantic analysis, and interpretation/compilation of Frut code.

Features

  • No-std compatible (uses only core and alloc)
  • Modular architecture for extensibility
  • Support for both interpretation and compilation workflows in the future

Installation

To use frut_lib, first add this to your Cargo.toml:

[dependencies]
frut_lib = "0.0.4"

For no_std environments, disable default features:

[dependencies]
frut_lib = { version = "0.0.4", default-features = false }

Usage

use frut_lib::parse_code;

fn main() {
    let result = parse_code("var x: int = 42;", "main.ft".to_string());
    match result.is_success() {
        false => println!("Found {} errors", result.errors.len()),
        true => println!("Analysis successful"),
    }
}

Examples

See the examples/ directory for more usage examples:

cargo run --example base
cargo run --example interp

Documentation

For documentation, visit docs.rs/frut_lib.

License

Licensed under the Apache License, Version 2.0 LICENSE.

Commit count: 0

cargo fmt