Skip to content

Commit

Permalink
Ability to add extra variables to actions in gen_test
Browse files Browse the repository at this point in the history
Pulled from 'instantiate' branch, commit a9f9196.
  • Loading branch information
lukemaurer committed Oct 20, 2023
1 parent 268ebbd commit c15dcfb
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions ocaml/testsuite/tests/templates/basic/gen_test.ml
Original file line number Diff line number Diff line change
Expand Up @@ -93,10 +93,11 @@ let tree_for_mode mode =
| None -> vars
| Some flags -> ("flags", flags) :: vars
in
let compile ?flags filenames =
Act (compiler, add_flags ~flags [
let add_extra ?(extra = []) vars = extra @ vars in
let compile ?flags ?extra filenames =
Act (compiler, add_flags ~flags (add_extra ?extra [
"module", filenames;
])
]))
in
let compile_bad ~ext ?flags module_ =
Branch (Seq [
Expand Down

0 comments on commit c15dcfb

Please sign in to comment.