@@ -10,7 +10,7 @@ function get(arr, i) {
1010
1111}
1212
13- function getExn ( arr , i ) {
13+ function getOrThrow ( arr , i ) {
1414 if ( ! ( i >= 0 && i < arr . length ) ) {
1515 throw {
1616 RE_EXN_ID : "Assert_failure" ,
@@ -34,13 +34,13 @@ function set(arr, i, v) {
3434 }
3535}
3636
37- function setExn ( arr , i , v ) {
37+ function setOrThrow ( arr , i , v ) {
3838 if ( ! ( i >= 0 && i < arr . length ) ) {
3939 throw {
4040 RE_EXN_ID : "Assert_failure" ,
4141 _1 : [
4242 "Belt_Array.res" ,
43- 49 ,
43+ 51 ,
4444 2
4545 ] ,
4646 Error : new Error ( )
@@ -582,6 +582,10 @@ function init(n, f) {
582582 return v ;
583583}
584584
585+ let getExn = getOrThrow ;
586+
587+ let setExn = setOrThrow ;
588+
585589let makeByU = makeBy ;
586590
587591let makeByAndShuffleU = makeByAndShuffle ;
@@ -636,8 +640,10 @@ let initU = init;
636640
637641exports . get = get ;
638642exports . getExn = getExn ;
643+ exports . getOrThrow = getOrThrow ;
639644exports . set = set ;
640645exports . setExn = setExn ;
646+ exports . setOrThrow = setOrThrow ;
641647exports . shuffleInPlace = shuffleInPlace ;
642648exports . shuffle = shuffle ;
643649exports . reverseInPlace = reverseInPlace ;
0 commit comments