Impl's and pointers

This commit is contained in:
2024-05-25 11:14:58 +02:00
parent b3db964a8e
commit 4cbf46da53
3 changed files with 34 additions and 3 deletions
+15 -1
View File
@@ -314,7 +314,21 @@ pub fn transpile(input: String, indent: u32, state: LexerState, options: &mut Op
transpile(
ast.tokens[1].value.clone(),
0,
LexerState { line: 1, column: 0 },
state,
options,
),
"}"
)
.as_str();
} else if ast.ast_type == AstType::Impl {
result += format!(
"impl {} {}{}{}",
&ast.tokens[0].value.clone(),
"{",
transpile(
ast.tokens[1].value.clone(),
0,
state,
options,
),
"}"