Ignore:
Timestamp:
Jan 19, 2011, 6:23:27 PM (9 years ago)
Author:
campbell
Message:

Port memory spaces changes to latest prototype compiler.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Deliverables/D2.3/8051-memoryspaces-branch/src/languages.ml

    r453 r460  
    241241  close_out cout
    242242
     243let rec find_clight = function
     244| [] -> None
     245| AstClight p :: t -> Some p
     246| _::t -> find_clight t
     247
     248let save_matita filename asts =
     249  match find_clight asts with
     250  | None -> Error.warning "during matita output" "No Clight AST."
     251  | Some prog -> begin
     252    let output_filename =
     253      Misc.SysExt.alternative
     254        (Filename.chop_extension filename
     255         ^ ".ma")
     256    in
     257    let cout = open_out output_filename in
     258    let fout = Format.formatter_of_out_channel cout in
     259    ClightPrintMatita.print_program fout prog;
     260    flush cout;
     261    close_out cout
     262  end
     263
    243264let interpret = function
    244265  | AstClight p ->
Note: See TracChangeset for help on using the changeset viewer.