9
9
* workings can be found in the book "Software Solutions in C" by
10
10
* Dale Schumacher, Academic Press, ISBN: 0-12-632360-7.
11
11
*
12
- * $Header: /cvsroot/pgsql/src/backend/utils/adt/cash.c,v 1.17 1997/10/03 13:10 :06 thomas Exp $
12
+ * $Header: /cvsroot/pgsql/src/backend/utils/adt/cash.c,v 1.18 1997/10/25 05:11 :06 thomas Exp $
13
13
*/
14
14
15
15
#include <stdio.h>
@@ -64,6 +64,10 @@ cash_in(const char *str)
64
64
csymbol ;
65
65
66
66
#ifdef USE_LOCALE
67
+ #ifdef CASHDEBUG
68
+ setlocale (LC_ALL ,"" );
69
+ lconvert = localeconv ();
70
+ #endif
67
71
if (lconvert == NULL )
68
72
lconvert = localeconv ();
69
73
@@ -85,6 +89,11 @@ cash_in(const char *str)
85
89
nsymbol = '-' ;
86
90
#endif
87
91
92
+ #ifdef CASHDEBUG
93
+ printf ("cashin- precision %d; decimal %c; thousands %c; currency %c; positive %c; negative %c\n" ,
94
+ fpoint ,dsymbol ,ssymbol ,csymbol ,psymbol ,nsymbol );
95
+ #endif
96
+
88
97
/* we need to add all sorts of checking here. For now just */
89
98
/* strip all leading whitespace and any leading dollar sign */
90
99
while (isspace (* s )|| * s == csymbol )