diff --git a/Cargo.toml b/Cargo.toml index b550ba2..43cd114 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "able-lang" +name = "able-script" version = "0.1.0" authors = ["able "] edition = "2018" diff --git a/README.md b/README.md new file mode 100644 index 0000000..08cc0e7 --- /dev/null +++ b/README.md @@ -0,0 +1,2 @@ +# Ablescript +Bravely going where some languages have gone before. diff --git a/able-lang-test/function.able b/able-lang-test/function.able new file mode 100644 index 0000000..a723c1c --- /dev/null +++ b/able-lang-test/function.able @@ -0,0 +1,9 @@ +functio something(a: isize, c: isize, r: &mut isize) { + *r = a + c; +} + +let a = 3; +let b = 4; +let mut r = 0; + +something(a, b, &mut r); diff --git a/src/const.rs b/src/const.rs index 7a07554..49b9ff2 100644 --- a/src/const.rs +++ b/src/const.rs @@ -1,3 +1,4 @@ +// NOTE(Able): Number constants pub const TAU: i32 = 6; pub const PI: i32 = 3; pub const E: i32 = 3; @@ -10,3 +11,5 @@ pub const GRAVITY: i32 = 10; pub const RNG: i32 = 12; pub const STD_RNG: i32 = 4; //The standard random number is 4 (source: https://xkcd.com/221/) pub const INF: i32 = i32::max_value(); + +pub const OCTOTHORPE: char = '#'; diff --git a/src/main.rs b/src/main.rs index 40bd9fc..a87d1cc 100644 --- a/src/main.rs +++ b/src/main.rs @@ -2,8 +2,8 @@ extern crate clap; use clap::{App, Arg}; mod base_55; fn main() { - let matches = App::new("My Super Program") - .version("1.0") + let matches = App::new("AbleScript") + .version(env!("CARGO_PKG_VERSION")) .author("Able ") .about("Does awesome things") .arg(