diff options
| author | Alasdair Armstrong | 2017-09-21 18:31:49 +0100 |
|---|---|---|
| committer | Alasdair Armstrong | 2017-09-21 18:31:49 +0100 |
| commit | 669bfc2cd34bda80e69ba6c75edbd3e4d57114cd (patch) | |
| tree | 8638cbd82f46433b8ae574cb04a924735005b90c /src/pretty_print_sail.ml | |
| parent | b097466ab11fd035dbfd5c7c51ea0644c62b92da (diff) | |
Refactored AST valspecs into single constructor
Diffstat (limited to 'src/pretty_print_sail.ml')
| -rw-r--r-- | src/pretty_print_sail.ml | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/pretty_print_sail.ml b/src/pretty_print_sail.ml index 0f943efa..72218bc3 100644 --- a/src/pretty_print_sail.ml +++ b/src/pretty_print_sail.ml @@ -385,15 +385,14 @@ let doc_default (DT_aux(df,_)) = match df with | DT_order(ord) -> separate space [string "default"; string "Order"; doc_ord ord] let doc_spec (VS_aux(v,_)) = match v with - | VS_val_spec(ts,id) -> + | VS_val_spec(ts,id,None,false) -> separate space [string "val"; doc_typscm ts; doc_id id] - | VS_cast_spec (ts, id) -> + | VS_val_spec (ts, id,None,true) -> separate space [string "val"; string "cast"; doc_typscm ts; doc_id id] - | VS_extern_no_rename(ts,id) -> - separate space [string "val"; string "extern"; doc_typscm ts; doc_id id] - | VS_extern_spec(ts,id,s) -> + | VS_val_spec(ts,id,Some ext,false) -> separate space [string "val"; string "extern"; doc_typscm ts; - doc_op equals (doc_id id) (dquotes (string s))] + doc_op equals (doc_id id) (dquotes (string ext))] + | _ -> failwith "Invalid valspec" let doc_namescm (Name_sect_aux(ns,_)) = match ns with | Name_sect_none -> empty |
