Fix some bugs found by SWIG version 3.0.5.

Prior to version 3.0.3 SWIG silently ignored invalid preprocessor directives.
See <https://github.com/swig/swig/issues/217>
This commit is contained in:
Mike Alexander 2015-02-23 18:26:45 -05:00
parent 207c01453e
commit e9972be932
4 changed files with 4 additions and 4 deletions

View File

@ -77,6 +77,6 @@ const char * gnc_locale_default_iso_currency_code (void);
return gnc_utf8_validate(str, -1, 0); return gnc_utf8_validate(str, -1, 0);
} }
%} %}
#elsif defined(SWIGPYTHON) #elif defined(SWIGPYTHON)
gboolean gnc_utf8_validate(const gchar *, gssize, const gchar**); gboolean gnc_utf8_validate(const gchar *, gssize, const gchar**);
#endif #endif

View File

@ -166,7 +166,7 @@ static GncInvoiceList * qof_query_run_for_invoices(QofQuery *q) {
SET_ENUM("GNC-INVOICE-VEND-CREDIT-NOTE"); SET_ENUM("GNC-INVOICE-VEND-CREDIT-NOTE");
SET_ENUM("GNC-INVOICE-EMPL-CREDIT-NOTE"); SET_ENUM("GNC-INVOICE-EMPL-CREDIT-NOTE");
#undefine SET_ENUM #undef SET_ENUM
} }
} }

View File

@ -355,7 +355,7 @@ KvpValue * kvp_frame_get_slot_path_gslist (KvpFrame *frame, GSList *key_path);
SET_ENUM("GNC-HOW-RND-ROUND"); SET_ENUM("GNC-HOW-RND-ROUND");
SET_ENUM("GNC-HOW-RND-NEVER"); SET_ENUM("GNC-HOW-RND-NEVER");
#undefine SET_ENUM #undef SET_ENUM
} }
} }

View File

@ -51,7 +51,7 @@ SCM scm_init_sw_gnc_html_module(void);
SET_ENUM("URL-TYPE-PRICE"); SET_ENUM("URL-TYPE-PRICE");
SET_ENUM("URL-TYPE-OTHER"); SET_ENUM("URL-TYPE-OTHER");
#undefine SET_ENUM #undef SET_ENUM
} }
} }