# HG changeset patch # User tuomov # Date 1097079881 -7200 # Node ID ebefcbcb126f53900eacec4c151b479120851a72 # Parent c60bc05a6d3847fbb25171fc9abd83821725a84a trunk: changeset 1789 Added some macros. diff -r c60bc05a6d38 -r ebefcbcb126f debug.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/debug.h Wed Oct 06 18:24:41 2004 +0200 @@ -0,0 +1,19 @@ +/* + * libtu/debug.h + * + * Copyright (c) Tuomo Valkonen 2004. + * + * You may distribute and modify this library under the terms of either + * the Clarified Artistic License or the GNU LGPL, version 2.1 or later. + */ + +#ifndef LIBTU_DEBUG_H +#define LIBTU_DEBUG_H + +#ifdef CF_DEBUG +#define D(X) X +#else +#define D(X) +#endif + +#endif /* LIBTU_DEBUG_H */ diff -r c60bc05a6d38 -r ebefcbcb126f locale.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/locale.h Wed Oct 06 18:24:41 2004 +0200 @@ -0,0 +1,27 @@ +/* + * libtu/locale.h + * + * Copyright (c) Tuomo Valkonen 2004. + * + * You may distribute and modify this library under the terms of either + * the Clarified Artistic License or the GNU LGPL, version 2.1 or later. + */ + +#ifndef LIBTU_LOCALE_H +#define LIBTU_LOCALE_H + +#ifdef CF_NO_LOCALE + +#define TR(X) X +#define DUMMY_TR(X) X + +#else + +#include + +#define TR(X) gettext(X) +#define DUMMY_TR(X) X + +#endif + +#endif /* LIBTU_LOCALE_H */ diff -r c60bc05a6d38 -r ebefcbcb126f output.h --- a/output.h Sat Jul 31 21:12:01 2004 +0200 +++ b/output.h Wed Oct 06 18:24:41 2004 +0200 @@ -14,6 +14,14 @@ #include "types.h" +#if __STDC_VERSION__ >= 199901L +#define WARN_FUNC(...) warn_obj(__func__, __VA_ARGS__) +#define WARN_ERR_FUNC() warn_err_obj(__func__) +#else +#define WARN_FUNC warn +#define WARN_ERR_FUNC() warn_err() +#endif + typedef void WarnHandler(const char *); extern WarnHandler *set_warn_handler(WarnHandler *handler);