about summary refs log tree commit diff stats
path: root/shell/macroexpand.mu
blob: 2f1cb5de2f03de5ec506d6857997eeca9e418e7a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
fn macroexpand expr-ah: (addr handle cell), globals: (addr global-table), trace: (addr trace) {
  # loop until convergence
  var expanded?/eax: boolean <- macroexpand-iter expr-ah, globals, trace
  compare expanded?, 0/false
  loop-if-!=
}

# return true if we found any macros
fn macroexpand-iter _expr-ah: (addr handle cell), globals: (addr global-table), trace: (addr trace) -> _/eax: boolean {
  return 0/false
}