/*
* Internal declarations for libcdecl.
* Copyright © 2021, 2023 Nick Bowler
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
#ifndef CDECL_INTERNAL_H_
#define CDECL_INTERNAL_H_
#include
#include
#define _(s) dgettext(PACKAGE, s)
#define N_(s) s
struct cdecl_error;
struct cdecl_declspec;
#if ENABLE_NLS
void cdecl__init_i18n(void);
#else
static inline void cdecl__init_i18n(void)
{
}
#endif
void cdecl__err(unsigned code, const char *fmt, ...);
void cdecl__errmsg(unsigned msg);
struct cdecl_declspec *cdecl__normalize_specs(struct cdecl_declspec *specs);
size_t cdecl__advance_(char **buf, size_t *n, size_t amount);
size_t cdecl__advance(char **buf, size_t *n, size_t amount);
size_t cdecl__explain_specs(char *buf, size_t n, struct cdecl_declspec *s,
unsigned mask);
size_t cdecl__explain_pre_specs(char *buf, size_t n, struct cdecl_declspec *s);
size_t cdecl__explain_post_specs(char *buf, size_t n, struct cdecl_declspec *s);
#endif