This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] metag: add extern C to header


From: Trevor Saunders <tbsaunde+binutils@tbsaunde.org>

Hi,

seems kind of obvious if we think its reasonable to include these headers from C++.

built and regtested metag-elf, ok?

Trev

include/ChangeLog:

2016-05-25  Trevor Saunders  <tbsaunde+binutils@tbsaunde.org>

	* opcode/metag.h: wrap declarations in extern "C".
---
 include/opcode/metag.h | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/include/opcode/metag.h b/include/opcode/metag.h
index 5bce87e..1ca6d9e 100644
--- a/include/opcode/metag.h
+++ b/include/opcode/metag.h
@@ -19,6 +19,10 @@
    Free Software Foundation, 51 Franklin Street - Fifth Floor, Boston,
    MA 02110-1301, USA.  */
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 enum metag_unit
 {
   UNIT_CT,
@@ -2077,3 +2081,7 @@ static const insn_template metag_optab[] =
 unsigned int metag_get_set_size_bytes (unsigned int opcode);
 unsigned int metag_get_set_ext_size_bytes (unsigned int opcode);
 unsigned int metag_cond_set_size_bytes (unsigned int opcode);
+
+#ifdef __cplusplus
+}
+#endif
-- 
2.8.1


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]