summaryrefslogtreecommitdiffstats
path: root/generic/tclStrToD.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-01-13 21:46:18 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-01-13 21:46:18 (GMT)
commitc6135def08ea1be2a47763a2877362b258cc3b90 (patch)
treef3beaaf7a215833f4b7b177676c3411481937547 /generic/tclStrToD.c
parent41e035d59b0c36c42cefeec6b76e24f274d16278 (diff)
downloadtcl-c6135def08ea1be2a47763a2877362b258cc3b90.zip
tcl-c6135def08ea1be2a47763a2877362b258cc3b90.tar.gz
tcl-c6135def08ea1be2a47763a2877362b258cc3b90.tar.bz2
Attempt to resolve a conflict between (unmodified) tommath.h and tcl.h in the definition of mp_int. See: [https://github.com/libtom/libtommath/pull/473]
Diffstat (limited to 'generic/tclStrToD.c')
-rw-r--r--generic/tclStrToD.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/generic/tclStrToD.c b/generic/tclStrToD.c
index 8939fa0..3c80afc 100644
--- a/generic/tclStrToD.c
+++ b/generic/tclStrToD.c
@@ -4553,10 +4553,11 @@ int
Tcl_InitBignumFromDouble(
Tcl_Interp *interp, /* For error message. */
double d, /* Number to convert. */
- mp_int *b) /* Place to store the result. */
+ void *big) /* Place to store the result. */
{
double fract;
int expt;
+ mp_int *b = (mp_int *)big;
/*
* Infinite values can't convert to bignum.
@@ -4607,11 +4608,12 @@ Tcl_InitBignumFromDouble(
double
TclBignumToDouble(
- const mp_int *a) /* Integer to convert. */
+ const void *big) /* Integer to convert. */
{
mp_int b;
int bits, shift, i, lsb;
double r;
+ const mp_int *a = (const mp_int *)big;
/*
@@ -4720,10 +4722,11 @@ TclBignumToDouble(
double
TclCeil(
- const mp_int *a) /* Integer to convert. */
+ const void *big) /* Integer to convert. */
{
double r = 0.0;
mp_int b;
+ const mp_int *a = (const mp_int *)big;
mp_init(&b);
if (mp_isneg(a)) {
@@ -4777,10 +4780,11 @@ TclCeil(
double
TclFloor(
- const mp_int *a) /* Integer to convert. */
+ const void *big) /* Integer to convert. */
{
double r = 0.0;
mp_int b;
+ const mp_int *a = (const mp_int *)big;
mp_init(&b);
if (mp_isneg(a)) {