Project

General

Profile

« Previous | Next » 

Revision 3ee26303

Added by LĂ©lio Brun 7 months ago

conditionnally print spec in machine code logs

View differences:

src/machine_code_common.ml
115 115
end
116 116

  
117 117
let pp_spec m =
118
  pp_print_list
119
    ~pp_open_box:pp_open_vbox0
120
    ~pp_prologue:pp_print_cut
121
    (fun fmt -> fprintf fmt "@[<h>--%@ %a@]" (PrintSpec.pp_spec m))
118
  if !Options.spec <> "no" then
119
    pp_print_list
120
      ~pp_open_box:pp_open_vbox0
121
      ~pp_prologue:pp_print_cut
122
      (fun fmt -> fprintf fmt "@[<h>--%@ %a@]" (PrintSpec.pp_spec m))
123
  else
124
    pp_print_nothing
122 125

  
123 126
let rec pp_instr m fmt i =
124 127
  let pp_val = pp_val m in
......
214 217
    (PrintSpec.pp_spec m) mp.mpformula
215 218

  
216 219
let pp_memory_packs m fmt =
217
  fprintf fmt
218
    "@[<v 2>memory_packs:@ %a@]"
219
    (pp_print_list (pp_memory_pack m))
220
  if !Options.spec <> "no" then
221
    fprintf fmt
222
      "@[<v 2>memory_packs:@ %a@]"
223
      (pp_print_list (pp_memory_pack m))
224
  else
225
    pp_print_nothing fmt
220 226

  
221 227
let pp_transition m fmt t =
222 228
  fprintf fmt
......
227 233
    (PrintSpec.pp_spec m) t.tformula
228 234

  
229 235
let pp_transitions m fmt =
230
  fprintf fmt
231
    "@[<v 2>transitions:@ %a@]"
232
    (pp_print_list (pp_transition m))
236
  if !Options.spec <> "no" then
237
    fprintf fmt
238
      "@[<v 2>transitions:@ %a@]"
239
      (pp_print_list (pp_transition m))
240
  else
241
    pp_print_nothing fmt
233 242

  
234 243
let pp_machine fmt m =
235 244
  fprintf fmt
src/options.ml
21 21
let track_exceptions = ref true
22 22
let ansi = ref false
23 23
let check = ref false
24
let spec = ref "acsl"
24
let spec = ref "no"
25 25
let output = ref "C"
26 26
let dest_dir = ref "."
27 27
let verbose_level = ref 1

Also available in: Unified diff