- (* If no initial target set on the command line, find
- * the first goal in the file.
- *)
- List.iter (
- function
- | Ast.Goal (name, [], _, _, _) ->
- if !initial_targets = [] then
- initial_targets := Ast.ECall (name, []) :: !initial_targets
- | Ast.Goal (name, _, _, _, _) ->
- if !initial_targets = [] then
- failwithf "%s: first target ā%sā has parameters and so cannot be used as the default target"
- filename name
- | _ -> ()
- ) file;
+ (* If no target was set on the command line, use "all ()". *)
+ let targets =
+ if targets <> [] then targets
+ else [Ast.ECall (Ast.noloc, "all", [])] in
+
+ if Cmdline.debug_flag then
+ Ast.print_env stderr env;