aboutsummaryrefslogtreecommitdiffstats
path: root/cparser/Elab.ml
diff options
context:
space:
mode:
Diffstat (limited to 'cparser/Elab.ml')
-rw-r--r--cparser/Elab.ml6
1 files changed, 3 insertions, 3 deletions
diff --git a/cparser/Elab.ml b/cparser/Elab.ml
index ceab0aa5..fb75c687 100644
--- a/cparser/Elab.ml
+++ b/cparser/Elab.ml
@@ -253,11 +253,11 @@ let elab_string_literal loc wide chars =
if wide then
CWStr chars
else begin
- let res = String.create (List.length chars) in
+ let res = Bytes.create (List.length chars) in
List.iteri
- (fun i c -> res.[i] <- Char.unsafe_chr (Int64.to_int c))
+ (fun i c -> Bytes.set res i (Char.unsafe_chr (Int64.to_int c)))
chars;
- CStr res
+ CStr (Bytes.to_string res)
end
let elab_constant loc = function