3 #ifndef SPECTMORPH_UTIL_HH 4 #define SPECTMORPH_UTIL_HH 12 typedef uint8_t uint8;
13 typedef int64_t int64;
14 typedef uint64_t uint64;
16 #define SPECTMORPH_CLASS_NON_COPYABLE(Class) private: Class (const Class&); Class& operator= (const Class&); 17 #define SPECTMORPH_PRINTF(format_idx, arg_idx) __attribute__ ((__format__ (__printf__, format_idx, arg_idx))) 19 std::string string_printf (
const char *format, ...) SPECTMORPH_PRINTF (1, 2);
20 std::
string string_vprintf (const
char *format, va_list vargs);
22 std::
string string_locale_printf (const
char *format, ...) SPECTMORPH_PRINTF (1, 2);
24 void sm_printf (const
char *format, ...) SPECTMORPH_PRINTF (1, 2);
28 INSTALL_DIR_TEMPLATES,
29 INSTALL_DIR_INSTRUMENTS
32 std::string sm_get_install_dir (InstallDir p);
39 std::string sm_get_user_dir (UserDir p);
40 std::string sm_get_default_plan();
51 bool constexpr operator== (Error v, int64_t n) {
return int64_t (v) == n; }
52 bool constexpr operator== (int64_t n, Error v) {
return n == int64_t (v); }
53 bool constexpr operator!= (Error v, int64_t n) {
return int64_t (v) != n; }
54 bool constexpr operator!= (int64_t n, Error v) {
return n != int64_t (v); }
56 const char *sm_error_blurb (Error error);
Definition: smalignedarray.cc:7