summaryrefslogtreecommitdiffstats
path: root/generic/tclTomMath.decls
diff options
context:
space:
mode:
Diffstat (limited to 'generic/tclTomMath.decls')
-rw-r--r--generic/tclTomMath.decls166
1 files changed, 91 insertions, 75 deletions
diff --git a/generic/tclTomMath.decls b/generic/tclTomMath.decls
index ab39e83..610a031 100644
--- a/generic/tclTomMath.decls
+++ b/generic/tclTomMath.decls
@@ -1,9 +1,8 @@
# tclTomMath.decls --
#
-# This file contains the declarations for the functions in
-# 'libtommath' that are contained within the Tcl library.
-# This file is used to generate the 'tclTomMathDecls.h' and
-# 'tclStubInit.c' files.
+# This file contains the declarations for the functions in 'libtommath'
+# that are contained within the Tcl library. This file is used to
+# generate the 'tclTomMathDecls.h' and 'tclStubInit.c' files.
#
# If you edit this file, advance the revision number (and the epoch
# if the new stubs are not backward compatible) in tclTomMathDecls.h
@@ -19,196 +18,197 @@ library tcl
interface tclTomMath
# hooks {tclTomMathInt}
+scspec EXTERN
# Declare each of the functions in the Tcl tommath interface
-declare 0 generic {
+declare 0 {
int TclBN_epoch(void)
}
-declare 1 generic {
+declare 1 {
int TclBN_revision(void)
}
-declare 2 generic {
+declare 2 {
int TclBN_mp_add(mp_int *a, mp_int *b, mp_int *c)
}
-declare 3 generic {
+declare 3 {
int TclBN_mp_add_d(mp_int *a, mp_digit b, mp_int *c)
}
-declare 4 generic {
+declare 4 {
int TclBN_mp_and(mp_int *a, mp_int *b, mp_int *c)
}
-declare 5 generic {
+declare 5 {
void TclBN_mp_clamp(mp_int *a)
}
-declare 6 generic {
+declare 6 {
void TclBN_mp_clear(mp_int *a)
}
-declare 7 generic {
+declare 7 {
void TclBN_mp_clear_multi(mp_int *a, ...)
}
-declare 8 generic {
- int TclBN_mp_cmp(mp_int *a, mp_int *b)
+declare 8 {
+ int TclBN_mp_cmp(const mp_int *a, const mp_int *b)
}
-declare 9 generic {
- int TclBN_mp_cmp_d(mp_int *a, mp_digit b)
+declare 9 {
+ int TclBN_mp_cmp_d(const mp_int *a, mp_digit b)
}
-declare 10 generic {
- int TclBN_mp_cmp_mag(mp_int *a, mp_int *b)
+declare 10 {
+ int TclBN_mp_cmp_mag(const mp_int *a, const mp_int *b)
}
-declare 11 generic {
- int TclBN_mp_copy(mp_int *a, mp_int *b)
+declare 11 {
+ int TclBN_mp_copy(const mp_int *a, mp_int *b)
}
-declare 12 generic {
- int TclBN_mp_count_bits(mp_int *a)
+declare 12 {
+ int TclBN_mp_count_bits(const mp_int *a)
}
-declare 13 generic {
+declare 13 {
int TclBN_mp_div(mp_int *a, mp_int *b, mp_int *q, mp_int *r)
}
-declare 14 generic {
+declare 14 {
int TclBN_mp_div_d(mp_int *a, mp_digit b, mp_int *q, mp_digit *r)
}
-declare 15 generic {
+declare 15 {
int TclBN_mp_div_2(mp_int *a, mp_int *q)
}
-declare 16 generic {
- int TclBN_mp_div_2d(mp_int *a, int b, mp_int *q, mp_int *r)
+declare 16 {
+ int TclBN_mp_div_2d(const mp_int *a, int b, mp_int *q, mp_int *r)
}
-declare 17 generic {
+declare 17 {
int TclBN_mp_div_3(mp_int *a, mp_int *q, mp_digit *r)
}
-declare 18 generic {
+declare 18 {
void TclBN_mp_exch(mp_int *a, mp_int *b)
}
-declare 19 generic {
+declare 19 {
int TclBN_mp_expt_d(mp_int *a, mp_digit b, mp_int *c)
}
-declare 20 generic {
+declare 20 {
int TclBN_mp_grow(mp_int *a, int size)
}
-declare 21 generic {
+declare 21 {
int TclBN_mp_init(mp_int *a)
}
-declare 22 generic {
+declare 22 {
int TclBN_mp_init_copy(mp_int *a, mp_int *b)
}
-declare 23 generic {
+declare 23 {
int TclBN_mp_init_multi(mp_int *a, ...)
}
-declare 24 generic {
+declare 24 {
int TclBN_mp_init_set(mp_int *a, mp_digit b)
}
-declare 25 generic {
+declare 25 {
int TclBN_mp_init_size(mp_int *a, int size)
}
-declare 26 generic {
+declare 26 {
int TclBN_mp_lshd(mp_int *a, int shift)
}
-declare 27 generic {
+declare 27 {
int TclBN_mp_mod(mp_int *a, mp_int *b, mp_int *r)
}
-declare 28 generic {
- int TclBN_mp_mod_2d(mp_int *a, int b, mp_int *r)
+declare 28 {
+ int TclBN_mp_mod_2d(const mp_int *a, int b, mp_int *r)
}
-declare 29 generic {
+declare 29 {
int TclBN_mp_mul(mp_int *a, mp_int *b, mp_int *p)
}
-declare 30 generic {
+declare 30 {
int TclBN_mp_mul_d(mp_int *a, mp_digit b, mp_int *p)
}
-declare 31 generic {
+declare 31 {
int TclBN_mp_mul_2(mp_int *a, mp_int *p)
}
-declare 32 generic {
- int TclBN_mp_mul_2d(mp_int *a, int d, mp_int *p)
+declare 32 {
+ int TclBN_mp_mul_2d(const mp_int *a, int d, mp_int *p)
}
-declare 33 generic {
- int TclBN_mp_neg(mp_int *a, mp_int *b)
+declare 33 {
+ int TclBN_mp_neg(const mp_int *a, mp_int *b)
}
-declare 34 generic {
+declare 34 {
int TclBN_mp_or(mp_int *a, mp_int *b, mp_int *c)
}
-declare 35 generic {
+declare 35 {
int TclBN_mp_radix_size(mp_int *a, int radix, int *size)
}
-declare 36 generic {
+declare 36 {
int TclBN_mp_read_radix(mp_int *a, const char *str, int radix)
}
-declare 37 generic {
+declare 37 {
void TclBN_mp_rshd(mp_int *a, int shift)
}
-declare 38 generic {
+declare 38 {
int TclBN_mp_shrink(mp_int *a)
}
-declare 39 generic {
+declare 39 {
void TclBN_mp_set(mp_int *a, mp_digit b)
}
-declare 40 generic {
+declare 40 {
int TclBN_mp_sqr(mp_int *a, mp_int *b)
}
-declare 41 generic {
+declare 41 {
int TclBN_mp_sqrt(mp_int *a, mp_int *b)
}
-declare 42 generic {
+declare 42 {
int TclBN_mp_sub(mp_int *a, mp_int *b, mp_int *c)
}
-declare 43 generic {
+declare 43 {
int TclBN_mp_sub_d(mp_int *a, mp_digit b, mp_int *c)
}
-declare 44 generic {
+declare 44 {
int TclBN_mp_to_unsigned_bin(mp_int *a, unsigned char *b)
}
-declare 45 generic {
+declare 45 {
int TclBN_mp_to_unsigned_bin_n(mp_int *a, unsigned char *b,
unsigned long *outlen)
}
-declare 46 generic {
+declare 46 {
int TclBN_mp_toradix_n(mp_int *a, char *str, int radix, int maxlen)
}
-declare 47 generic {
+declare 47 {
int TclBN_mp_unsigned_bin_size(mp_int *a)
}
-declare 48 generic {
+declare 48 {
int TclBN_mp_xor(mp_int *a, mp_int *b, mp_int *c)
}
-declare 49 generic {
+declare 49 {
void TclBN_mp_zero(mp_int *a)
}
# internal routines to libtommath - should not be called but must be
# exported to accommodate the "tommath" extension
-declare 50 generic {
+declare 50 {
void TclBN_reverse(unsigned char *s, int len)
}
-declare 51 generic {
+declare 51 {
int TclBN_fast_s_mp_mul_digs(mp_int *a, mp_int *b, mp_int *c, int digs)
}
-declare 52 generic {
+declare 52 {
int TclBN_fast_s_mp_sqr(mp_int *a, mp_int *b)
}
-declare 53 generic {
+declare 53 {
int TclBN_mp_karatsuba_mul(mp_int *a, mp_int *b, mp_int *c)
}
-declare 54 generic {
+declare 54 {
int TclBN_mp_karatsuba_sqr(mp_int *a, mp_int *b)
}
-declare 55 generic {
+declare 55 {
int TclBN_mp_toom_mul(mp_int *a, mp_int *b, mp_int *c)
}
-declare 56 generic {
+declare 56 {
int TclBN_mp_toom_sqr(mp_int *a, mp_int *b)
}
-declare 57 generic {
+declare 57 {
int TclBN_s_mp_add(mp_int *a, mp_int *b, mp_int *c)
}
-declare 58 generic {
+declare 58 {
int TclBN_s_mp_mul_digs(mp_int *a, mp_int *b, mp_int *c, int digs)
}
-declare 59 generic {
+declare 59 {
int TclBN_s_mp_sqr(mp_int *a, mp_int *b)
}
-declare 60 generic {
+declare 60 {
int TclBN_s_mp_sub(mp_int *a, mp_int *b, mp_int *c)
}
declare 61 {
@@ -218,5 +218,21 @@ declare 62 {
int TclBN_mp_set_int(mp_int *a, unsigned long i)
}
declare 63 {
- int TclBN_mp_cnt_lsb(mp_int *a)
+ int TclBN_mp_cnt_lsb(const mp_int *a)
}
+
+# Formerly internal API to allow initialisation of bignums without knowing the
+# typedefs of how a bignum works internally.
+declare 64 {
+ void TclBNInitBignumFromLong(mp_int *bignum, long initVal)
+}
+declare 65 {
+ void TclBNInitBignumFromWideInt(mp_int *bignum, Tcl_WideInt initVal)
+}
+declare 66 {
+ void TclBNInitBignumFromWideUInt(mp_int *bignum, Tcl_WideUInt initVal)
+}
+
+# Local Variables:
+# mode: tcl
+# End: