Skip to content

Commit

Permalink
🚧 WIP
Browse files Browse the repository at this point in the history
semver: chore
  • Loading branch information
Somfic committed Jan 3, 2025
1 parent dee0a83 commit 84e1662
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,21 @@ pub mod lexer;
pub mod parser;

const INPUT: &str = "
type Color {
Red,
Hex (string),
Rgb { r: int, g: int, b: int }
}
code Color {
fn to_hex(color ~ Color) -> string {
match color:
Red => \"#FF0000\"
Hex(hex) => hex
Rgb { r, g, b } => format!(\"#{:02X}{:02X}{:02X}\", r, g, b)
}
}
fn main() {
let a = |a ~ int| { 1 + 1; a };
Expand Down

0 comments on commit 84e1662

Please sign in to comment.