Skip to content

Commit

Permalink
js-annot: string ops have to be prefixed by caml_
Browse files Browse the repository at this point in the history
  • Loading branch information
seliopou committed Feb 10, 2018
1 parent 1835af1 commit 1055904
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions lib/runtime.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@
----------------------------------------------------------------------------*/

//Provides: angstrom_bigstring_blit_to_bytes
//Requires: string_unsafe_set, caml_ba_get_1
//Requires: caml_string_unsafe_set, caml_ba_get_1
function angstrom_bigstring_blit_to_bytes(src, src_off, dst, dst_off, len) {
for (var i = 0; i < len; i++) {
string_unsafe_set(dst, dst_off + i, caml_ba_get_1(src, src_off + i));
caml_string_unsafe_set(dst, dst_off + i, caml_ba_get_1(src, src_off + i));
}
}

Expand All @@ -48,9 +48,9 @@ function angstrom_bigstring_blit_to_bigstring(src, src_off, dst, dst_off, len) {
}

//Provides: angstrom_bigstring_blit_from_bytes
//Requires: caml_ba_set_1, string_unsafe_get
//Requires: caml_ba_set_1, caml_string_unsafe_get
function angstrom_bigstring_blit_from_bytes(src, src_off, dst, dst_off, len) {
for (var i = 0; i < len; i++) {
caml_ba_set_1(dst, dst_off + i, string_unsafe_get(src, src_off + i));
caml_ba_set_1(dst, dst_off + i, caml_string_unsafe_get(src, src_off + i));
}
}

0 comments on commit 1055904

Please sign in to comment.