1 /* ISC license. */ 2 3 #ifndef EXLSN_H 4 #define EXLSN_H 5 6 #include <skalibs/gccattributes.h> 7 #include <skalibs/stralloc.h> 8 #include <skalibs/genalloc.h> 9 10 typedef struct exlsn_s exlsn_t, *exlsn_t_ref ; 11 struct exlsn_s 12 { 13 stralloc vars ; 14 stralloc values ; 15 genalloc data ; /* array of elsubst */ 16 stralloc modifs ; 17 } ; 18 19 #define EXLSN_ZERO { .vars = STRALLOC_ZERO, .values = STRALLOC_ZERO, .data = GENALLOC_ZERO, .modifs = STRALLOC_ZERO } 20 21 extern void exlsn_free (exlsn_t *) ; 22 23 typedef int exlsnfunc_t (int, char const **, char const *const *, exlsn_t *) ; 24 typedef exlsnfunc_t *exlsnfunc_t_ref ; 25 26 extern exlsnfunc_t exlsn_define ; 27 extern exlsnfunc_t exlsn_importas ; 28 extern exlsnfunc_t exlsn_elglob ; 29 extern exlsnfunc_t exlsn_exlp ; 30 extern exlsnfunc_t exlsn_multidefine ; 31 32 extern int exlp (unsigned int, char const *const *, exlsn_t *) ; 33 extern void el_substandrun (int, char const *const *, char const *const *, exlsn_t const *) gccattr_noreturn ; 34 extern void el_substandrun_str (stralloc *, size_t, char const *const *, exlsn_t const *) gccattr_noreturn ; 35 extern void exlsn_main (int, char const **, char const *const *, exlsnfunc_t *, char const *) gccattr_noreturn ; 36 37 #endif 38