Skip to content
/ bait Public
forked from bait-lang/bait

Commit

Permalink
gen: remove more obsolete code
Browse files Browse the repository at this point in the history
missed in bait-lang#294
  • Loading branch information
serkonda7 committed Jan 21, 2025
1 parent d083b10 commit 1d40641
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 17 deletions.
3 changes: 0 additions & 3 deletions lib/bait/gen/c/cgen.bt
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,6 @@ struct Gen {
mut is_lhs_assign bool
mut is_array_map_set bool
mut is_for_loop_head bool
// Testing
mut has_test_begin bool
mut has_test_end bool
// Cached comptime variables
mut baitexe string
mut baitdir string
Expand Down
6 changes: 0 additions & 6 deletions lib/bait/gen/c/fun.bt
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,6 @@ fun (mut g Gen) anon_fun(node ast.AnonFun) {
}

fun (mut g Gen) fun_decl(node ast.FunDecl) {
if node.mix_name == 'testsuite_begin' {
g.has_test_begin = true
} else if node.mix_name == 'testsuite_end' {
g.has_test_end = true
}

if node.generic_names.length > 0 and g.cur_concrete_types.length == 0 {
gtypes := g.table.generic_fun_types[node.key()]
for conc_types in gtypes {
Expand Down
6 changes: 0 additions & 6 deletions lib/bait/gen/js/fun.bt
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,6 @@ package js
import bait.ast

fun (mut g Gen) fun_decl(node ast.FunDecl) {
if node.name == 'testsuite_begin' {
g.has_test_begin = true
} else if node.name == 'testsuite_end' {
g.has_test_end = true
}

if node.generic_names.length > 0 and g.cur_concrete_types.length == 0 {
gtypes := g.table.generic_fun_types[node.key()]
for conc_types in gtypes {
Expand Down
2 changes: 0 additions & 2 deletions lib/bait/gen/js/jsgen.bt
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,6 @@ struct Gen {
mut is_for_loop_head bool
mut is_lhs_assign bool
mut is_array_map_set bool
mut has_test_begin bool
mut has_test_end bool
// Cached comptime variables
mut baitexe string
mut baitdir string
Expand Down

0 comments on commit 1d40641

Please sign in to comment.