Skip to content

Commit

Permalink
compiler: c_ctx -> ctx
Browse files Browse the repository at this point in the history
  • Loading branch information
StunxFS committed Dec 1, 2024
1 parent b216cb5 commit 2831c3c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
10 changes: 5 additions & 5 deletions compiler/mod.v
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ import compiler.context
import compiler.parser

pub fn run(args []string) {
mut c_ctx := &context.CContext{}
mut ctx := &context.CContext{}

context.push(c_ctx)
context.push(ctx)
defer { context.pop() }

c_ctx.options = context.parse_args(args)
ctx.options = context.parse_args(args)

mut p := parser.new(c_ctx)
mut p := parser.new(ctx)
p.parse()
c_ctx.abort_if_errors()
ctx.abort_if_errors()
}
1 change: 1 addition & 0 deletions compiler/tokenizer/mod.v
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ const cr = 13
const backslash = `\\`
const num_sep = `_`

@[inline]
fn is_new_line(ch u8) bool {
return ch in [cr, lf]
}
Expand Down

0 comments on commit 2831c3c

Please sign in to comment.