alua

Crates.ioalua
lib.rsalua
version0.2.0
sourcesrc
created_at2024-04-23 15:12:24.446607
updated_at2024-10-28 14:44:16.159851
descriptionA Rust library for generating lua lsp annotations from Rust types
homepage
repositoryhttps://github.com/eievui5/alua
max_upload_size
id1217707
size23,568
Evie (evie-calico)

documentation

README

alua

A Rust library for generating luals annotations from Rust types.

Example

use alua::*;

#[derive(ClassAnnotation)]
#[alua(fields = [
    "method fun(self: Example, message: string) - Send a message",
])]
struct Example {
    /// test
    #[allow(unused)]
    field: u32,
}

fn main() {
    print!("{}", Example::class_annotation());
}

This produces the following output:

--- @class Example
--- @field field integer - test
--- @field method fun(self: Example, message: string) - Send a message
Commit count: 17

cargo fmt