From 6e5f53c09490a510344a65d26f5e3989a048fcdf Mon Sep 17 00:00:00 2001 From: Alexandre Duret-Lutz <adl@lrde.epita.fr> Date: Fri, 17 May 2013 19:01:15 +0200 Subject: [PATCH] argmatch: port to C++ * lib/argmatch.h [__cplusplus]: Add extern "C". --- ChangeLog | 3 +++ lib/argmatch.h | 8 ++++++++ 2 files changed, 11 insertions(+) diff --git a/ChangeLog b/ChangeLog index c8ea9e0195..de7f539939 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2013-05-17 Alexandre Duret-Lutz <adl@lrde.epita.fr> + argmatch: port to C++ + * lib/argmatch.h [__cplusplus]: Add extern "C". + argp: typo fix * lib/argp-help.c: Typo in comment. diff --git a/lib/argmatch.h b/lib/argmatch.h index 2e0275cfe8..e4c8027144 100644 --- a/lib/argmatch.h +++ b/lib/argmatch.h @@ -26,6 +26,10 @@ # include "verify.h" +#ifdef __cplusplus +extern "C" { +#endif + # define ARRAY_CARDINALITY(Array) (sizeof (Array) / sizeof *(Array)) /* Assert there are as many real arguments as there are values @@ -100,4 +104,8 @@ char const *argmatch_to_argument (char const *value, argmatch_to_argument (Value, Arglist, \ (char const *) (Vallist), sizeof *(Vallist)) +#ifdef __cplusplus +} +#endif + #endif /* ARGMATCH_H_ */ -- 2.39.5