@provablehq/wasm 0.9.6 → 0.9.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -956,27 +956,27 @@ export class I128 {
956
956
  private constructor();
957
957
  free(): void;
958
958
  /**
959
- * Creates from string.
959
+ * Construct an integer from a string representation.
960
960
  */
961
961
  static fromString(s: string): I128;
962
962
  /**
963
- * To string.
963
+ * Get the string representation of the integer.
964
964
  */
965
965
  toString(): string;
966
966
  /**
967
- * From bytes (LE).
967
+ * Get the byte array representation of the integer.
968
968
  */
969
969
  static fromBytesLe(bytes: Uint8Array): I128;
970
970
  /**
971
- * To bytes (LE).
971
+ * Construct an integer from a byte array representation.
972
972
  */
973
973
  toBytesLe(): Uint8Array;
974
974
  /**
975
- * From bits.
975
+ * Construct an integer from a boolean array representation.
976
976
  */
977
977
  static fromBitsLe(bits: Array<any>): I128;
978
978
  /**
979
- * To bits.
979
+ * Get the boolean array representation of the integer.
980
980
  */
981
981
  toBitsLe(): Array<any>;
982
982
  /**
@@ -988,15 +988,15 @@ export class I128 {
988
988
  */
989
989
  absWrapped(): I128;
990
990
  /**
991
- * Wrapped addition.
991
+ * Wrapped addition with another integer.
992
992
  */
993
993
  addWrapped(other: I128): I128;
994
994
  /**
995
- * Wrapped subtraction.
995
+ * Wrapped subtraction with another integer.
996
996
  */
997
997
  subWrapped(other: I128): I128;
998
998
  /**
999
- * Wrapped multiplication.
999
+ * Wrapped multiplication with another integer.
1000
1000
  */
1001
1001
  mulWrapped(other: I128): I128;
1002
1002
  /**
@@ -1004,51 +1004,51 @@ export class I128 {
1004
1004
  */
1005
1005
  divWrapped(other: I128): I128;
1006
1006
  /**
1007
- * Power to a u8 exponent.
1007
+ * Exponentiate the integer with a u8 exponent.
1008
1008
  */
1009
1009
  powU8(exponent: U8): I128;
1010
1010
  /**
1011
- * Power to a u16 exponent.
1011
+ * Exponentiate the integer with a u16 exponent.
1012
1012
  */
1013
1013
  powU16(exponent: U16): I128;
1014
1014
  /**
1015
- * Power to a u32 exponent.
1015
+ * Exponentiate the integer with a u32 exponent.
1016
1016
  */
1017
1017
  powU32(exponent: U32): I128;
1018
1018
  /**
1019
- * Negates the integer (e.g., 5 → -5).
1019
+ * Negate the integer (e.g., 5 → -5).
1020
1020
  */
1021
1021
  neg(): I128;
1022
1022
  /**
1023
- * Checks equality with another integer.
1023
+ * Check equality with another integer.
1024
1024
  */
1025
1025
  equals(other: I128): boolean;
1026
1026
  /**
1027
- * Remainder.
1027
+ * Get the remainder from integer division.
1028
1028
  */
1029
1029
  rem(other: I128): I128;
1030
1030
  /**
1031
- * Wrapped remainder.
1031
+ * Get the remainder from an integer division which wraps if there's an overflow.
1032
1032
  */
1033
1033
  remWrapped(other: I128): I128;
1034
1034
  /**
1035
- * Convert to Scalar.
1035
+ * Convert the integer to a Scalar value.
1036
1036
  */
1037
1037
  toScalar(): Scalar;
1038
1038
  /**
1039
- * Convert to plaintext.
1039
+ * Convert the integer to the Plaintext type. This must be done before hashing an integer to ensure it matches hashes with a leo/aleo program.
1040
1040
  */
1041
1041
  toPlaintext(): Plaintext;
1042
1042
  /**
1043
- * Convert from Field.
1043
+ * Attempt to construct the integer from a field element.
1044
1044
  */
1045
1045
  static fromField(field: Field): I128;
1046
1046
  /**
1047
- * Convert from Fields.
1047
+ * Atttempt to construct the integer from a list of field elements.
1048
1048
  */
1049
1049
  static fromFields(fields: Array<any>): I128;
1050
1050
  /**
1051
- * Clone.
1051
+ * Clone the integer in wasm memory.
1052
1052
  */
1053
1053
  clone(): I128;
1054
1054
  }
@@ -1056,27 +1056,27 @@ export class I16 {
1056
1056
  private constructor();
1057
1057
  free(): void;
1058
1058
  /**
1059
- * Creates from string.
1059
+ * Construct an integer from a string representation.
1060
1060
  */
1061
1061
  static fromString(s: string): I16;
1062
1062
  /**
1063
- * To string.
1063
+ * Get the string representation of the integer.
1064
1064
  */
1065
1065
  toString(): string;
1066
1066
  /**
1067
- * From bytes (LE).
1067
+ * Get the byte array representation of the integer.
1068
1068
  */
1069
1069
  static fromBytesLe(bytes: Uint8Array): I16;
1070
1070
  /**
1071
- * To bytes (LE).
1071
+ * Construct an integer from a byte array representation.
1072
1072
  */
1073
1073
  toBytesLe(): Uint8Array;
1074
1074
  /**
1075
- * From bits.
1075
+ * Construct an integer from a boolean array representation.
1076
1076
  */
1077
1077
  static fromBitsLe(bits: Array<any>): I16;
1078
1078
  /**
1079
- * To bits.
1079
+ * Get the boolean array representation of the integer.
1080
1080
  */
1081
1081
  toBitsLe(): Array<any>;
1082
1082
  /**
@@ -1088,15 +1088,15 @@ export class I16 {
1088
1088
  */
1089
1089
  absWrapped(): I16;
1090
1090
  /**
1091
- * Wrapped addition.
1091
+ * Wrapped addition with another integer.
1092
1092
  */
1093
1093
  addWrapped(other: I16): I16;
1094
1094
  /**
1095
- * Wrapped subtraction.
1095
+ * Wrapped subtraction with another integer.
1096
1096
  */
1097
1097
  subWrapped(other: I16): I16;
1098
1098
  /**
1099
- * Wrapped multiplication.
1099
+ * Wrapped multiplication with another integer.
1100
1100
  */
1101
1101
  mulWrapped(other: I16): I16;
1102
1102
  /**
@@ -1104,51 +1104,51 @@ export class I16 {
1104
1104
  */
1105
1105
  divWrapped(other: I16): I16;
1106
1106
  /**
1107
- * Power to a u8 exponent.
1107
+ * Exponentiate the integer with a u8 exponent.
1108
1108
  */
1109
1109
  powU8(exponent: U8): I16;
1110
1110
  /**
1111
- * Power to a u16 exponent.
1111
+ * Exponentiate the integer with a u16 exponent.
1112
1112
  */
1113
1113
  powU16(exponent: U16): I16;
1114
1114
  /**
1115
- * Power to a u32 exponent.
1115
+ * Exponentiate the integer with a u32 exponent.
1116
1116
  */
1117
1117
  powU32(exponent: U32): I16;
1118
1118
  /**
1119
- * Negates the integer (e.g., 5 → -5).
1119
+ * Negate the integer (e.g., 5 → -5).
1120
1120
  */
1121
1121
  neg(): I16;
1122
1122
  /**
1123
- * Checks equality with another integer.
1123
+ * Check equality with another integer.
1124
1124
  */
1125
1125
  equals(other: I16): boolean;
1126
1126
  /**
1127
- * Remainder.
1127
+ * Get the remainder from integer division.
1128
1128
  */
1129
1129
  rem(other: I16): I16;
1130
1130
  /**
1131
- * Wrapped remainder.
1131
+ * Get the remainder from an integer division which wraps if there's an overflow.
1132
1132
  */
1133
1133
  remWrapped(other: I16): I16;
1134
1134
  /**
1135
- * Convert to Scalar.
1135
+ * Convert the integer to a Scalar value.
1136
1136
  */
1137
1137
  toScalar(): Scalar;
1138
1138
  /**
1139
- * Convert to plaintext.
1139
+ * Convert the integer to the Plaintext type. This must be done before hashing an integer to ensure it matches hashes with a leo/aleo program.
1140
1140
  */
1141
1141
  toPlaintext(): Plaintext;
1142
1142
  /**
1143
- * Convert from Field.
1143
+ * Attempt to construct the integer from a field element.
1144
1144
  */
1145
1145
  static fromField(field: Field): I16;
1146
1146
  /**
1147
- * Convert from Fields.
1147
+ * Atttempt to construct the integer from a list of field elements.
1148
1148
  */
1149
1149
  static fromFields(fields: Array<any>): I16;
1150
1150
  /**
1151
- * Clone.
1151
+ * Clone the integer in wasm memory.
1152
1152
  */
1153
1153
  clone(): I16;
1154
1154
  }
@@ -1156,27 +1156,27 @@ export class I32 {
1156
1156
  private constructor();
1157
1157
  free(): void;
1158
1158
  /**
1159
- * Creates from string.
1159
+ * Construct an integer from a string representation.
1160
1160
  */
1161
1161
  static fromString(s: string): I32;
1162
1162
  /**
1163
- * To string.
1163
+ * Get the string representation of the integer.
1164
1164
  */
1165
1165
  toString(): string;
1166
1166
  /**
1167
- * From bytes (LE).
1167
+ * Get the byte array representation of the integer.
1168
1168
  */
1169
1169
  static fromBytesLe(bytes: Uint8Array): I32;
1170
1170
  /**
1171
- * To bytes (LE).
1171
+ * Construct an integer from a byte array representation.
1172
1172
  */
1173
1173
  toBytesLe(): Uint8Array;
1174
1174
  /**
1175
- * From bits.
1175
+ * Construct an integer from a boolean array representation.
1176
1176
  */
1177
1177
  static fromBitsLe(bits: Array<any>): I32;
1178
1178
  /**
1179
- * To bits.
1179
+ * Get the boolean array representation of the integer.
1180
1180
  */
1181
1181
  toBitsLe(): Array<any>;
1182
1182
  /**
@@ -1188,15 +1188,15 @@ export class I32 {
1188
1188
  */
1189
1189
  absWrapped(): I32;
1190
1190
  /**
1191
- * Wrapped addition.
1191
+ * Wrapped addition with another integer.
1192
1192
  */
1193
1193
  addWrapped(other: I32): I32;
1194
1194
  /**
1195
- * Wrapped subtraction.
1195
+ * Wrapped subtraction with another integer.
1196
1196
  */
1197
1197
  subWrapped(other: I32): I32;
1198
1198
  /**
1199
- * Wrapped multiplication.
1199
+ * Wrapped multiplication with another integer.
1200
1200
  */
1201
1201
  mulWrapped(other: I32): I32;
1202
1202
  /**
@@ -1204,51 +1204,51 @@ export class I32 {
1204
1204
  */
1205
1205
  divWrapped(other: I32): I32;
1206
1206
  /**
1207
- * Power to a u8 exponent.
1207
+ * Exponentiate the integer with a u8 exponent.
1208
1208
  */
1209
1209
  powU8(exponent: U8): I32;
1210
1210
  /**
1211
- * Power to a u16 exponent.
1211
+ * Exponentiate the integer with a u16 exponent.
1212
1212
  */
1213
1213
  powU16(exponent: U16): I32;
1214
1214
  /**
1215
- * Power to a u32 exponent.
1215
+ * Exponentiate the integer with a u32 exponent.
1216
1216
  */
1217
1217
  powU32(exponent: U32): I32;
1218
1218
  /**
1219
- * Negates the integer (e.g., 5 → -5).
1219
+ * Negate the integer (e.g., 5 → -5).
1220
1220
  */
1221
1221
  neg(): I32;
1222
1222
  /**
1223
- * Checks equality with another integer.
1223
+ * Check equality with another integer.
1224
1224
  */
1225
1225
  equals(other: I32): boolean;
1226
1226
  /**
1227
- * Remainder.
1227
+ * Get the remainder from integer division.
1228
1228
  */
1229
1229
  rem(other: I32): I32;
1230
1230
  /**
1231
- * Wrapped remainder.
1231
+ * Get the remainder from an integer division which wraps if there's an overflow.
1232
1232
  */
1233
1233
  remWrapped(other: I32): I32;
1234
1234
  /**
1235
- * Convert to Scalar.
1235
+ * Convert the integer to a Scalar value.
1236
1236
  */
1237
1237
  toScalar(): Scalar;
1238
1238
  /**
1239
- * Convert to plaintext.
1239
+ * Convert the integer to the Plaintext type. This must be done before hashing an integer to ensure it matches hashes with a leo/aleo program.
1240
1240
  */
1241
1241
  toPlaintext(): Plaintext;
1242
1242
  /**
1243
- * Convert from Field.
1243
+ * Attempt to construct the integer from a field element.
1244
1244
  */
1245
1245
  static fromField(field: Field): I32;
1246
1246
  /**
1247
- * Convert from Fields.
1247
+ * Atttempt to construct the integer from a list of field elements.
1248
1248
  */
1249
1249
  static fromFields(fields: Array<any>): I32;
1250
1250
  /**
1251
- * Clone.
1251
+ * Clone the integer in wasm memory.
1252
1252
  */
1253
1253
  clone(): I32;
1254
1254
  }
@@ -1256,27 +1256,27 @@ export class I64 {
1256
1256
  private constructor();
1257
1257
  free(): void;
1258
1258
  /**
1259
- * Creates from string.
1259
+ * Construct an integer from a string representation.
1260
1260
  */
1261
1261
  static fromString(s: string): I64;
1262
1262
  /**
1263
- * To string.
1263
+ * Get the string representation of the integer.
1264
1264
  */
1265
1265
  toString(): string;
1266
1266
  /**
1267
- * From bytes (LE).
1267
+ * Get the byte array representation of the integer.
1268
1268
  */
1269
1269
  static fromBytesLe(bytes: Uint8Array): I64;
1270
1270
  /**
1271
- * To bytes (LE).
1271
+ * Construct an integer from a byte array representation.
1272
1272
  */
1273
1273
  toBytesLe(): Uint8Array;
1274
1274
  /**
1275
- * From bits.
1275
+ * Construct an integer from a boolean array representation.
1276
1276
  */
1277
1277
  static fromBitsLe(bits: Array<any>): I64;
1278
1278
  /**
1279
- * To bits.
1279
+ * Get the boolean array representation of the integer.
1280
1280
  */
1281
1281
  toBitsLe(): Array<any>;
1282
1282
  /**
@@ -1288,15 +1288,15 @@ export class I64 {
1288
1288
  */
1289
1289
  absWrapped(): I64;
1290
1290
  /**
1291
- * Wrapped addition.
1291
+ * Wrapped addition with another integer.
1292
1292
  */
1293
1293
  addWrapped(other: I64): I64;
1294
1294
  /**
1295
- * Wrapped subtraction.
1295
+ * Wrapped subtraction with another integer.
1296
1296
  */
1297
1297
  subWrapped(other: I64): I64;
1298
1298
  /**
1299
- * Wrapped multiplication.
1299
+ * Wrapped multiplication with another integer.
1300
1300
  */
1301
1301
  mulWrapped(other: I64): I64;
1302
1302
  /**
@@ -1304,51 +1304,51 @@ export class I64 {
1304
1304
  */
1305
1305
  divWrapped(other: I64): I64;
1306
1306
  /**
1307
- * Power to a u8 exponent.
1307
+ * Exponentiate the integer with a u8 exponent.
1308
1308
  */
1309
1309
  powU8(exponent: U8): I64;
1310
1310
  /**
1311
- * Power to a u16 exponent.
1311
+ * Exponentiate the integer with a u16 exponent.
1312
1312
  */
1313
1313
  powU16(exponent: U16): I64;
1314
1314
  /**
1315
- * Power to a u32 exponent.
1315
+ * Exponentiate the integer with a u32 exponent.
1316
1316
  */
1317
1317
  powU32(exponent: U32): I64;
1318
1318
  /**
1319
- * Negates the integer (e.g., 5 → -5).
1319
+ * Negate the integer (e.g., 5 → -5).
1320
1320
  */
1321
1321
  neg(): I64;
1322
1322
  /**
1323
- * Checks equality with another integer.
1323
+ * Check equality with another integer.
1324
1324
  */
1325
1325
  equals(other: I64): boolean;
1326
1326
  /**
1327
- * Remainder.
1327
+ * Get the remainder from integer division.
1328
1328
  */
1329
1329
  rem(other: I64): I64;
1330
1330
  /**
1331
- * Wrapped remainder.
1331
+ * Get the remainder from an integer division which wraps if there's an overflow.
1332
1332
  */
1333
1333
  remWrapped(other: I64): I64;
1334
1334
  /**
1335
- * Convert to Scalar.
1335
+ * Convert the integer to a Scalar value.
1336
1336
  */
1337
1337
  toScalar(): Scalar;
1338
1338
  /**
1339
- * Convert to plaintext.
1339
+ * Convert the integer to the Plaintext type. This must be done before hashing an integer to ensure it matches hashes with a leo/aleo program.
1340
1340
  */
1341
1341
  toPlaintext(): Plaintext;
1342
1342
  /**
1343
- * Convert from Field.
1343
+ * Attempt to construct the integer from a field element.
1344
1344
  */
1345
1345
  static fromField(field: Field): I64;
1346
1346
  /**
1347
- * Convert from Fields.
1347
+ * Atttempt to construct the integer from a list of field elements.
1348
1348
  */
1349
1349
  static fromFields(fields: Array<any>): I64;
1350
1350
  /**
1351
- * Clone.
1351
+ * Clone the integer in wasm memory.
1352
1352
  */
1353
1353
  clone(): I64;
1354
1354
  }
@@ -1356,27 +1356,27 @@ export class I8 {
1356
1356
  private constructor();
1357
1357
  free(): void;
1358
1358
  /**
1359
- * Creates from string.
1359
+ * Construct an integer from a string representation.
1360
1360
  */
1361
1361
  static fromString(s: string): I8;
1362
1362
  /**
1363
- * To string.
1363
+ * Get the string representation of the integer.
1364
1364
  */
1365
1365
  toString(): string;
1366
1366
  /**
1367
- * From bytes (LE).
1367
+ * Get the byte array representation of the integer.
1368
1368
  */
1369
1369
  static fromBytesLe(bytes: Uint8Array): I8;
1370
1370
  /**
1371
- * To bytes (LE).
1371
+ * Construct an integer from a byte array representation.
1372
1372
  */
1373
1373
  toBytesLe(): Uint8Array;
1374
1374
  /**
1375
- * From bits.
1375
+ * Construct an integer from a boolean array representation.
1376
1376
  */
1377
1377
  static fromBitsLe(bits: Array<any>): I8;
1378
1378
  /**
1379
- * To bits.
1379
+ * Get the boolean array representation of the integer.
1380
1380
  */
1381
1381
  toBitsLe(): Array<any>;
1382
1382
  /**
@@ -1388,15 +1388,15 @@ export class I8 {
1388
1388
  */
1389
1389
  absWrapped(): I8;
1390
1390
  /**
1391
- * Wrapped addition.
1391
+ * Wrapped addition with another integer.
1392
1392
  */
1393
1393
  addWrapped(other: I8): I8;
1394
1394
  /**
1395
- * Wrapped subtraction.
1395
+ * Wrapped subtraction with another integer.
1396
1396
  */
1397
1397
  subWrapped(other: I8): I8;
1398
1398
  /**
1399
- * Wrapped multiplication.
1399
+ * Wrapped multiplication with another integer.
1400
1400
  */
1401
1401
  mulWrapped(other: I8): I8;
1402
1402
  /**
@@ -1404,51 +1404,51 @@ export class I8 {
1404
1404
  */
1405
1405
  divWrapped(other: I8): I8;
1406
1406
  /**
1407
- * Power to a u8 exponent.
1407
+ * Exponentiate the integer with a u8 exponent.
1408
1408
  */
1409
1409
  powU8(exponent: U8): I8;
1410
1410
  /**
1411
- * Power to a u16 exponent.
1411
+ * Exponentiate the integer with a u16 exponent.
1412
1412
  */
1413
1413
  powU16(exponent: U16): I8;
1414
1414
  /**
1415
- * Power to a u32 exponent.
1415
+ * Exponentiate the integer with a u32 exponent.
1416
1416
  */
1417
1417
  powU32(exponent: U32): I8;
1418
1418
  /**
1419
- * Negates the integer (e.g., 5 → -5).
1419
+ * Negate the integer (e.g., 5 → -5).
1420
1420
  */
1421
1421
  neg(): I8;
1422
1422
  /**
1423
- * Checks equality with another integer.
1423
+ * Check equality with another integer.
1424
1424
  */
1425
1425
  equals(other: I8): boolean;
1426
1426
  /**
1427
- * Remainder.
1427
+ * Get the remainder from integer division.
1428
1428
  */
1429
1429
  rem(other: I8): I8;
1430
1430
  /**
1431
- * Wrapped remainder.
1431
+ * Get the remainder from an integer division which wraps if there's an overflow.
1432
1432
  */
1433
1433
  remWrapped(other: I8): I8;
1434
1434
  /**
1435
- * Convert to Scalar.
1435
+ * Convert the integer to a Scalar value.
1436
1436
  */
1437
1437
  toScalar(): Scalar;
1438
1438
  /**
1439
- * Convert to plaintext.
1439
+ * Convert the integer to the Plaintext type. This must be done before hashing an integer to ensure it matches hashes with a leo/aleo program.
1440
1440
  */
1441
1441
  toPlaintext(): Plaintext;
1442
1442
  /**
1443
- * Convert from Field.
1443
+ * Attempt to construct the integer from a field element.
1444
1444
  */
1445
1445
  static fromField(field: Field): I8;
1446
1446
  /**
1447
- * Convert from Fields.
1447
+ * Atttempt to construct the integer from a list of field elements.
1448
1448
  */
1449
1449
  static fromFields(fields: Array<any>): I8;
1450
1450
  /**
1451
- * Clone.
1451
+ * Clone the integer in wasm memory.
1452
1452
  */
1453
1453
  clone(): I8;
1454
1454
  }
@@ -3330,27 +3330,27 @@ export class U128 {
3330
3330
  private constructor();
3331
3331
  free(): void;
3332
3332
  /**
3333
- * Creates from string.
3333
+ * Construct an integer from a string representation.
3334
3334
  */
3335
3335
  static fromString(s: string): U128;
3336
3336
  /**
3337
- * To string.
3337
+ * Get the string representation of the integer.
3338
3338
  */
3339
3339
  toString(): string;
3340
3340
  /**
3341
- * From bytes (LE).
3341
+ * Get the byte array representation of the integer.
3342
3342
  */
3343
3343
  static fromBytesLe(bytes: Uint8Array): U128;
3344
3344
  /**
3345
- * To bytes (LE).
3345
+ * Construct an integer from a byte array representation.
3346
3346
  */
3347
3347
  toBytesLe(): Uint8Array;
3348
3348
  /**
3349
- * From bits.
3349
+ * Construct an integer from a boolean array representation.
3350
3350
  */
3351
3351
  static fromBitsLe(bits: Array<any>): U128;
3352
3352
  /**
3353
- * To bits.
3353
+ * Get the boolean array representation of the integer.
3354
3354
  */
3355
3355
  toBitsLe(): Array<any>;
3356
3356
  /**
@@ -3362,15 +3362,15 @@ export class U128 {
3362
3362
  */
3363
3363
  absWrapped(): U128;
3364
3364
  /**
3365
- * Wrapped addition.
3365
+ * Wrapped addition with another integer.
3366
3366
  */
3367
3367
  addWrapped(other: U128): U128;
3368
3368
  /**
3369
- * Wrapped subtraction.
3369
+ * Wrapped subtraction with another integer.
3370
3370
  */
3371
3371
  subWrapped(other: U128): U128;
3372
3372
  /**
3373
- * Wrapped multiplication.
3373
+ * Wrapped multiplication with another integer.
3374
3374
  */
3375
3375
  mulWrapped(other: U128): U128;
3376
3376
  /**
@@ -3378,51 +3378,51 @@ export class U128 {
3378
3378
  */
3379
3379
  divWrapped(other: U128): U128;
3380
3380
  /**
3381
- * Power to a u8 exponent.
3381
+ * Exponentiate the integer with a u8 exponent.
3382
3382
  */
3383
3383
  powU8(exponent: U8): U128;
3384
3384
  /**
3385
- * Power to a u16 exponent.
3385
+ * Exponentiate the integer with a u16 exponent.
3386
3386
  */
3387
3387
  powU16(exponent: U16): U128;
3388
3388
  /**
3389
- * Power to a u32 exponent.
3389
+ * Exponentiate the integer with a u32 exponent.
3390
3390
  */
3391
3391
  powU32(exponent: U32): U128;
3392
3392
  /**
3393
- * Negates the integer (e.g., 5 → -5).
3393
+ * Negate the integer (e.g., 5 → -5).
3394
3394
  */
3395
3395
  neg(): U128;
3396
3396
  /**
3397
- * Checks equality with another integer.
3397
+ * Check equality with another integer.
3398
3398
  */
3399
3399
  equals(other: U128): boolean;
3400
3400
  /**
3401
- * Remainder.
3401
+ * Get the remainder from integer division.
3402
3402
  */
3403
3403
  rem(other: U128): U128;
3404
3404
  /**
3405
- * Wrapped remainder.
3405
+ * Get the remainder from an integer division which wraps if there's an overflow.
3406
3406
  */
3407
3407
  remWrapped(other: U128): U128;
3408
3408
  /**
3409
- * Convert to Scalar.
3409
+ * Convert the integer to a Scalar value.
3410
3410
  */
3411
3411
  toScalar(): Scalar;
3412
3412
  /**
3413
- * Convert to plaintext.
3413
+ * Convert the integer to the Plaintext type. This must be done before hashing an integer to ensure it matches hashes with a leo/aleo program.
3414
3414
  */
3415
3415
  toPlaintext(): Plaintext;
3416
3416
  /**
3417
- * Convert from Field.
3417
+ * Attempt to construct the integer from a field element.
3418
3418
  */
3419
3419
  static fromField(field: Field): U128;
3420
3420
  /**
3421
- * Convert from Fields.
3421
+ * Atttempt to construct the integer from a list of field elements.
3422
3422
  */
3423
3423
  static fromFields(fields: Array<any>): U128;
3424
3424
  /**
3425
- * Clone.
3425
+ * Clone the integer in wasm memory.
3426
3426
  */
3427
3427
  clone(): U128;
3428
3428
  }
@@ -3430,27 +3430,27 @@ export class U16 {
3430
3430
  private constructor();
3431
3431
  free(): void;
3432
3432
  /**
3433
- * Creates from string.
3433
+ * Construct an integer from a string representation.
3434
3434
  */
3435
3435
  static fromString(s: string): U16;
3436
3436
  /**
3437
- * To string.
3437
+ * Get the string representation of the integer.
3438
3438
  */
3439
3439
  toString(): string;
3440
3440
  /**
3441
- * From bytes (LE).
3441
+ * Get the byte array representation of the integer.
3442
3442
  */
3443
3443
  static fromBytesLe(bytes: Uint8Array): U16;
3444
3444
  /**
3445
- * To bytes (LE).
3445
+ * Construct an integer from a byte array representation.
3446
3446
  */
3447
3447
  toBytesLe(): Uint8Array;
3448
3448
  /**
3449
- * From bits.
3449
+ * Construct an integer from a boolean array representation.
3450
3450
  */
3451
3451
  static fromBitsLe(bits: Array<any>): U16;
3452
3452
  /**
3453
- * To bits.
3453
+ * Get the boolean array representation of the integer.
3454
3454
  */
3455
3455
  toBitsLe(): Array<any>;
3456
3456
  /**
@@ -3462,15 +3462,15 @@ export class U16 {
3462
3462
  */
3463
3463
  absWrapped(): U16;
3464
3464
  /**
3465
- * Wrapped addition.
3465
+ * Wrapped addition with another integer.
3466
3466
  */
3467
3467
  addWrapped(other: U16): U16;
3468
3468
  /**
3469
- * Wrapped subtraction.
3469
+ * Wrapped subtraction with another integer.
3470
3470
  */
3471
3471
  subWrapped(other: U16): U16;
3472
3472
  /**
3473
- * Wrapped multiplication.
3473
+ * Wrapped multiplication with another integer.
3474
3474
  */
3475
3475
  mulWrapped(other: U16): U16;
3476
3476
  /**
@@ -3478,51 +3478,51 @@ export class U16 {
3478
3478
  */
3479
3479
  divWrapped(other: U16): U16;
3480
3480
  /**
3481
- * Power to a u8 exponent.
3481
+ * Exponentiate the integer with a u8 exponent.
3482
3482
  */
3483
3483
  powU8(exponent: U8): U16;
3484
3484
  /**
3485
- * Power to a u16 exponent.
3485
+ * Exponentiate the integer with a u16 exponent.
3486
3486
  */
3487
3487
  powU16(exponent: U16): U16;
3488
3488
  /**
3489
- * Power to a u32 exponent.
3489
+ * Exponentiate the integer with a u32 exponent.
3490
3490
  */
3491
3491
  powU32(exponent: U32): U16;
3492
3492
  /**
3493
- * Negates the integer (e.g., 5 → -5).
3493
+ * Negate the integer (e.g., 5 → -5).
3494
3494
  */
3495
3495
  neg(): U16;
3496
3496
  /**
3497
- * Checks equality with another integer.
3497
+ * Check equality with another integer.
3498
3498
  */
3499
3499
  equals(other: U16): boolean;
3500
3500
  /**
3501
- * Remainder.
3501
+ * Get the remainder from integer division.
3502
3502
  */
3503
3503
  rem(other: U16): U16;
3504
3504
  /**
3505
- * Wrapped remainder.
3505
+ * Get the remainder from an integer division which wraps if there's an overflow.
3506
3506
  */
3507
3507
  remWrapped(other: U16): U16;
3508
3508
  /**
3509
- * Convert to Scalar.
3509
+ * Convert the integer to a Scalar value.
3510
3510
  */
3511
3511
  toScalar(): Scalar;
3512
3512
  /**
3513
- * Convert to plaintext.
3513
+ * Convert the integer to the Plaintext type. This must be done before hashing an integer to ensure it matches hashes with a leo/aleo program.
3514
3514
  */
3515
3515
  toPlaintext(): Plaintext;
3516
3516
  /**
3517
- * Convert from Field.
3517
+ * Attempt to construct the integer from a field element.
3518
3518
  */
3519
3519
  static fromField(field: Field): U16;
3520
3520
  /**
3521
- * Convert from Fields.
3521
+ * Atttempt to construct the integer from a list of field elements.
3522
3522
  */
3523
3523
  static fromFields(fields: Array<any>): U16;
3524
3524
  /**
3525
- * Clone.
3525
+ * Clone the integer in wasm memory.
3526
3526
  */
3527
3527
  clone(): U16;
3528
3528
  }
@@ -3530,27 +3530,27 @@ export class U32 {
3530
3530
  private constructor();
3531
3531
  free(): void;
3532
3532
  /**
3533
- * Creates from string.
3533
+ * Construct an integer from a string representation.
3534
3534
  */
3535
3535
  static fromString(s: string): U32;
3536
3536
  /**
3537
- * To string.
3537
+ * Get the string representation of the integer.
3538
3538
  */
3539
3539
  toString(): string;
3540
3540
  /**
3541
- * From bytes (LE).
3541
+ * Get the byte array representation of the integer.
3542
3542
  */
3543
3543
  static fromBytesLe(bytes: Uint8Array): U32;
3544
3544
  /**
3545
- * To bytes (LE).
3545
+ * Construct an integer from a byte array representation.
3546
3546
  */
3547
3547
  toBytesLe(): Uint8Array;
3548
3548
  /**
3549
- * From bits.
3549
+ * Construct an integer from a boolean array representation.
3550
3550
  */
3551
3551
  static fromBitsLe(bits: Array<any>): U32;
3552
3552
  /**
3553
- * To bits.
3553
+ * Get the boolean array representation of the integer.
3554
3554
  */
3555
3555
  toBitsLe(): Array<any>;
3556
3556
  /**
@@ -3562,15 +3562,15 @@ export class U32 {
3562
3562
  */
3563
3563
  absWrapped(): U32;
3564
3564
  /**
3565
- * Wrapped addition.
3565
+ * Wrapped addition with another integer.
3566
3566
  */
3567
3567
  addWrapped(other: U32): U32;
3568
3568
  /**
3569
- * Wrapped subtraction.
3569
+ * Wrapped subtraction with another integer.
3570
3570
  */
3571
3571
  subWrapped(other: U32): U32;
3572
3572
  /**
3573
- * Wrapped multiplication.
3573
+ * Wrapped multiplication with another integer.
3574
3574
  */
3575
3575
  mulWrapped(other: U32): U32;
3576
3576
  /**
@@ -3578,51 +3578,51 @@ export class U32 {
3578
3578
  */
3579
3579
  divWrapped(other: U32): U32;
3580
3580
  /**
3581
- * Power to a u8 exponent.
3581
+ * Exponentiate the integer with a u8 exponent.
3582
3582
  */
3583
3583
  powU8(exponent: U8): U32;
3584
3584
  /**
3585
- * Power to a u16 exponent.
3585
+ * Exponentiate the integer with a u16 exponent.
3586
3586
  */
3587
3587
  powU16(exponent: U16): U32;
3588
3588
  /**
3589
- * Power to a u32 exponent.
3589
+ * Exponentiate the integer with a u32 exponent.
3590
3590
  */
3591
3591
  powU32(exponent: U32): U32;
3592
3592
  /**
3593
- * Negates the integer (e.g., 5 → -5).
3593
+ * Negate the integer (e.g., 5 → -5).
3594
3594
  */
3595
3595
  neg(): U32;
3596
3596
  /**
3597
- * Checks equality with another integer.
3597
+ * Check equality with another integer.
3598
3598
  */
3599
3599
  equals(other: U32): boolean;
3600
3600
  /**
3601
- * Remainder.
3601
+ * Get the remainder from integer division.
3602
3602
  */
3603
3603
  rem(other: U32): U32;
3604
3604
  /**
3605
- * Wrapped remainder.
3605
+ * Get the remainder from an integer division which wraps if there's an overflow.
3606
3606
  */
3607
3607
  remWrapped(other: U32): U32;
3608
3608
  /**
3609
- * Convert to Scalar.
3609
+ * Convert the integer to a Scalar value.
3610
3610
  */
3611
3611
  toScalar(): Scalar;
3612
3612
  /**
3613
- * Convert to plaintext.
3613
+ * Convert the integer to the Plaintext type. This must be done before hashing an integer to ensure it matches hashes with a leo/aleo program.
3614
3614
  */
3615
3615
  toPlaintext(): Plaintext;
3616
3616
  /**
3617
- * Convert from Field.
3617
+ * Attempt to construct the integer from a field element.
3618
3618
  */
3619
3619
  static fromField(field: Field): U32;
3620
3620
  /**
3621
- * Convert from Fields.
3621
+ * Atttempt to construct the integer from a list of field elements.
3622
3622
  */
3623
3623
  static fromFields(fields: Array<any>): U32;
3624
3624
  /**
3625
- * Clone.
3625
+ * Clone the integer in wasm memory.
3626
3626
  */
3627
3627
  clone(): U32;
3628
3628
  }
@@ -3630,27 +3630,27 @@ export class U64 {
3630
3630
  private constructor();
3631
3631
  free(): void;
3632
3632
  /**
3633
- * Creates from string.
3633
+ * Construct an integer from a string representation.
3634
3634
  */
3635
3635
  static fromString(s: string): U64;
3636
3636
  /**
3637
- * To string.
3637
+ * Get the string representation of the integer.
3638
3638
  */
3639
3639
  toString(): string;
3640
3640
  /**
3641
- * From bytes (LE).
3641
+ * Get the byte array representation of the integer.
3642
3642
  */
3643
3643
  static fromBytesLe(bytes: Uint8Array): U64;
3644
3644
  /**
3645
- * To bytes (LE).
3645
+ * Construct an integer from a byte array representation.
3646
3646
  */
3647
3647
  toBytesLe(): Uint8Array;
3648
3648
  /**
3649
- * From bits.
3649
+ * Construct an integer from a boolean array representation.
3650
3650
  */
3651
3651
  static fromBitsLe(bits: Array<any>): U64;
3652
3652
  /**
3653
- * To bits.
3653
+ * Get the boolean array representation of the integer.
3654
3654
  */
3655
3655
  toBitsLe(): Array<any>;
3656
3656
  /**
@@ -3662,15 +3662,15 @@ export class U64 {
3662
3662
  */
3663
3663
  absWrapped(): U64;
3664
3664
  /**
3665
- * Wrapped addition.
3665
+ * Wrapped addition with another integer.
3666
3666
  */
3667
3667
  addWrapped(other: U64): U64;
3668
3668
  /**
3669
- * Wrapped subtraction.
3669
+ * Wrapped subtraction with another integer.
3670
3670
  */
3671
3671
  subWrapped(other: U64): U64;
3672
3672
  /**
3673
- * Wrapped multiplication.
3673
+ * Wrapped multiplication with another integer.
3674
3674
  */
3675
3675
  mulWrapped(other: U64): U64;
3676
3676
  /**
@@ -3678,51 +3678,51 @@ export class U64 {
3678
3678
  */
3679
3679
  divWrapped(other: U64): U64;
3680
3680
  /**
3681
- * Power to a u8 exponent.
3681
+ * Exponentiate the integer with a u8 exponent.
3682
3682
  */
3683
3683
  powU8(exponent: U8): U64;
3684
3684
  /**
3685
- * Power to a u16 exponent.
3685
+ * Exponentiate the integer with a u16 exponent.
3686
3686
  */
3687
3687
  powU16(exponent: U16): U64;
3688
3688
  /**
3689
- * Power to a u32 exponent.
3689
+ * Exponentiate the integer with a u32 exponent.
3690
3690
  */
3691
3691
  powU32(exponent: U32): U64;
3692
3692
  /**
3693
- * Negates the integer (e.g., 5 → -5).
3693
+ * Negate the integer (e.g., 5 → -5).
3694
3694
  */
3695
3695
  neg(): U64;
3696
3696
  /**
3697
- * Checks equality with another integer.
3697
+ * Check equality with another integer.
3698
3698
  */
3699
3699
  equals(other: U64): boolean;
3700
3700
  /**
3701
- * Remainder.
3701
+ * Get the remainder from integer division.
3702
3702
  */
3703
3703
  rem(other: U64): U64;
3704
3704
  /**
3705
- * Wrapped remainder.
3705
+ * Get the remainder from an integer division which wraps if there's an overflow.
3706
3706
  */
3707
3707
  remWrapped(other: U64): U64;
3708
3708
  /**
3709
- * Convert to Scalar.
3709
+ * Convert the integer to a Scalar value.
3710
3710
  */
3711
3711
  toScalar(): Scalar;
3712
3712
  /**
3713
- * Convert to plaintext.
3713
+ * Convert the integer to the Plaintext type. This must be done before hashing an integer to ensure it matches hashes with a leo/aleo program.
3714
3714
  */
3715
3715
  toPlaintext(): Plaintext;
3716
3716
  /**
3717
- * Convert from Field.
3717
+ * Attempt to construct the integer from a field element.
3718
3718
  */
3719
3719
  static fromField(field: Field): U64;
3720
3720
  /**
3721
- * Convert from Fields.
3721
+ * Atttempt to construct the integer from a list of field elements.
3722
3722
  */
3723
3723
  static fromFields(fields: Array<any>): U64;
3724
3724
  /**
3725
- * Clone.
3725
+ * Clone the integer in wasm memory.
3726
3726
  */
3727
3727
  clone(): U64;
3728
3728
  }
@@ -3730,27 +3730,27 @@ export class U8 {
3730
3730
  private constructor();
3731
3731
  free(): void;
3732
3732
  /**
3733
- * Creates from string.
3733
+ * Construct an integer from a string representation.
3734
3734
  */
3735
3735
  static fromString(s: string): U8;
3736
3736
  /**
3737
- * To string.
3737
+ * Get the string representation of the integer.
3738
3738
  */
3739
3739
  toString(): string;
3740
3740
  /**
3741
- * From bytes (LE).
3741
+ * Get the byte array representation of the integer.
3742
3742
  */
3743
3743
  static fromBytesLe(bytes: Uint8Array): U8;
3744
3744
  /**
3745
- * To bytes (LE).
3745
+ * Construct an integer from a byte array representation.
3746
3746
  */
3747
3747
  toBytesLe(): Uint8Array;
3748
3748
  /**
3749
- * From bits.
3749
+ * Construct an integer from a boolean array representation.
3750
3750
  */
3751
3751
  static fromBitsLe(bits: Array<any>): U8;
3752
3752
  /**
3753
- * To bits.
3753
+ * Get the boolean array representation of the integer.
3754
3754
  */
3755
3755
  toBitsLe(): Array<any>;
3756
3756
  /**
@@ -3762,15 +3762,15 @@ export class U8 {
3762
3762
  */
3763
3763
  absWrapped(): U8;
3764
3764
  /**
3765
- * Wrapped addition.
3765
+ * Wrapped addition with another integer.
3766
3766
  */
3767
3767
  addWrapped(other: U8): U8;
3768
3768
  /**
3769
- * Wrapped subtraction.
3769
+ * Wrapped subtraction with another integer.
3770
3770
  */
3771
3771
  subWrapped(other: U8): U8;
3772
3772
  /**
3773
- * Wrapped multiplication.
3773
+ * Wrapped multiplication with another integer.
3774
3774
  */
3775
3775
  mulWrapped(other: U8): U8;
3776
3776
  /**
@@ -3778,51 +3778,51 @@ export class U8 {
3778
3778
  */
3779
3779
  divWrapped(other: U8): U8;
3780
3780
  /**
3781
- * Power to a u8 exponent.
3781
+ * Exponentiate the integer with a u8 exponent.
3782
3782
  */
3783
3783
  powU8(exponent: U8): U8;
3784
3784
  /**
3785
- * Power to a u16 exponent.
3785
+ * Exponentiate the integer with a u16 exponent.
3786
3786
  */
3787
3787
  powU16(exponent: U16): U8;
3788
3788
  /**
3789
- * Power to a u32 exponent.
3789
+ * Exponentiate the integer with a u32 exponent.
3790
3790
  */
3791
3791
  powU32(exponent: U32): U8;
3792
3792
  /**
3793
- * Negates the integer (e.g., 5 → -5).
3793
+ * Negate the integer (e.g., 5 → -5).
3794
3794
  */
3795
3795
  neg(): U8;
3796
3796
  /**
3797
- * Checks equality with another integer.
3797
+ * Check equality with another integer.
3798
3798
  */
3799
3799
  equals(other: U8): boolean;
3800
3800
  /**
3801
- * Remainder.
3801
+ * Get the remainder from integer division.
3802
3802
  */
3803
3803
  rem(other: U8): U8;
3804
3804
  /**
3805
- * Wrapped remainder.
3805
+ * Get the remainder from an integer division which wraps if there's an overflow.
3806
3806
  */
3807
3807
  remWrapped(other: U8): U8;
3808
3808
  /**
3809
- * Convert to Scalar.
3809
+ * Convert the integer to a Scalar value.
3810
3810
  */
3811
3811
  toScalar(): Scalar;
3812
3812
  /**
3813
- * Convert to plaintext.
3813
+ * Convert the integer to the Plaintext type. This must be done before hashing an integer to ensure it matches hashes with a leo/aleo program.
3814
3814
  */
3815
3815
  toPlaintext(): Plaintext;
3816
3816
  /**
3817
- * Convert from Field.
3817
+ * Attempt to construct the integer from a field element.
3818
3818
  */
3819
3819
  static fromField(field: Field): U8;
3820
3820
  /**
3821
- * Convert from Fields.
3821
+ * Atttempt to construct the integer from a list of field elements.
3822
3822
  */
3823
3823
  static fromFields(fields: Array<any>): U8;
3824
3824
  /**
3825
- * Clone.
3825
+ * Clone the integer in wasm memory.
3826
3826
  */
3827
3827
  clone(): U8;
3828
3828
  }
@@ -4050,6 +4050,12 @@ export class VerifyingKey {
4050
4050
  * @returns {String} String representation of the verifying key
4051
4051
  */
4052
4052
  toString(): string;
4053
+ /**
4054
+ * Get the number of constraints associated with the circuit
4055
+ *
4056
+ * @returns {number} The number of constraints
4057
+ */
4058
+ numConstraints(): number;
4053
4059
  }
4054
4060
  export class ViewKey {
4055
4061
  private constructor();