29 #ifndef ARB_GLOBAL_DEFS_H
33 #define ca_assert(cond) arb_assert(cond)
63 const char *
get_msg()
const {
return msg; }
64 void replace_msg(
const char *new_msg)
const { freedup(msg, new_msg); }
77 static bool show_warnings;
80 static bool shown() {
return show_warnings; }
84 show_warnings =
false;
99 return str ? strlen(str) : 0;
103 char *
result = ARB_alloc<char>(len+1);
104 memcpy(result, str, len);
117 #define WORD_SEP ",.; ?:!)]}"
125 (field[0] ==
'\n' && !field[1]);
130 char *nothing = ARB_alloc<char>(2);
138 if (copy) freedup(entry, content);
144 #define lookup_keyword(keyword,table) ___lookup_keyword(keyword, table, ARRAY_ELEMS(table))
147 #error global.h included twice
CONSTEXPR_INLINE int str0len(const char *str)
CONSTEXPR_INLINE bool str_iequal(const char *s1, const char *s2)
bool is_import_gap(const char c)
DECLARE_ASSIGNMENT_OPERATOR(Convaln_exception)
char * ARB_strdup(const char *str)
const char * get_msg() const
CONSTEXPR_INLINE bool has_content(const char *field)
bool copy_content(char *&entry, const char *content)
Convaln_exception(int error_code, const char *error_msg)
bool is_word_char(char ch)
CONSTEXPR_INLINE bool is_end_mark(char ch)
void replace_msg(const char *new_msg) const
Convaln_exception(const Convaln_exception &other)
static void copy(double **i, double **j)
static const Convaln_exception * exception_thrown()
CONSTEXPR_INLINE int max(int t1, int t2)
CONSTEXPR_INLINE bool has_no_content(const char *field)
CONSTEXPR_INLINE int min(int t1, int t2)
CONSTEXPR_INLINE bool str_equal(const char *s1, const char *s2)
CONSTEXPR_INLINE int count_spaces(const char *str)
char * strndup(const char *str, int len)
CONSTEXPR_INLINE bool is_sequence_terminator(const char *str)
bool occurs_in(char ch, const char *in)