diff options
| author | Alasdair Armstrong | 2017-12-13 20:38:24 +0000 |
|---|---|---|
| committer | Alasdair Armstrong | 2017-12-13 21:07:18 +0000 |
| commit | e636947dd964eb849cfeff528fe43a85fee7583a (patch) | |
| tree | a5898231c62af9eaca02d7d6386feb6e48c7fe95 /src/reporting_basic.ml | |
| parent | 2682a259a2a4a4ee34ddd6be6ea6f5dc3a3a15b7 (diff) | |
Cleanup code by fixing compiler warnings, and fix ocaml compilation
Add the ast.sed script we need to build sail. Currently we just need
this to fix up the locations in the AST but it will be removed once we
can share locations between ocaml and lem.
Diffstat (limited to 'src/reporting_basic.ml')
| -rw-r--r-- | src/reporting_basic.ml | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/reporting_basic.ml b/src/reporting_basic.ml index 166e0517..af1f85d0 100644 --- a/src/reporting_basic.ml +++ b/src/reporting_basic.ml @@ -97,7 +97,7 @@ let rec skip_lines in_chan = function | n when n <= 0 -> () - | n -> input_line in_chan; skip_lines in_chan (n - 1) + | n -> ignore (input_line in_chan); skip_lines in_chan (n - 1) let rec read_lines in_chan = function | n when n <= 0 -> [] @@ -186,9 +186,9 @@ let read_from_file_pos2 p1 p2 = let ic = open_in p1.Lexing.pos_fname in let _ = seek_in ic s in let l = (e - s) in - let buf = String.create l in + let buf = Bytes.create l in let _ = input ic buf 0 l in - let _ = match multi with None -> () | Some sk -> String.fill buf 0 sk ' ' in + let _ = match multi with None -> () | Some sk -> Bytes.fill buf 0 sk ' ' in let _ = close_in ic in (buf, not (multi = None)) |
