[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
c-strtod: make it usable in C++
From: |
Bruno Haible |
Subject: |
c-strtod: make it usable in C++ |
Date: |
Sun, 28 May 2017 13:52:54 +0200 |
User-agent: |
KMail/5.1.3 (Linux/4.4.0-78-generic; KDE/5.18.0; x86_64; ; ) |
Support for using this module in C++ mode. GNU clisp needs it.
2017-05-28 Bruno Haible <address@hidden>
c-strtod: Make it usable in C++ mode.
* lib/c-strtod.h: Add 'extern "C"' marker for C++.
diff --git a/lib/c-strtod.h b/lib/c-strtod.h
index 7aa511d..121fff4 100644
--- a/lib/c-strtod.h
+++ b/lib/c-strtod.h
@@ -15,6 +15,10 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
+#ifdef __cplusplus
+extern "C" {
+#endif
+
/* Parse the initial portion of the string pointed to by NPTR as a floating-
point number (in decimal or hexadecimal notation), like in the C locale:
accepting only the ASCII digits '0'..'9', and only '.' as decimal point
@@ -35,3 +39,7 @@
- In case of other error, return 0 and set errno, for example to ENOMEM. */
extern double c_strtod (char const *nptr, char **endptr);
extern long double c_strtold (char const *nptr, char **endptr);
+
+#ifdef __cplusplus
+}
+#endif
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- c-strtod: make it usable in C++,
Bruno Haible <=