Structures for AEL - the Asterisk extension language. More...
#include "asterisk/paths.h"
#include "pval.h"
Go to the source code of this file.
Data Structures | |
struct | ael_extension |
struct | ael_priority |
struct | parse_io |
Defines | |
#define | QUAD_MAX (0x7fffffffffffffffLL) |
#define | QUAD_MIN (-0x7fffffffffffffffLL-1) |
Typedefs | |
typedef void * | yyscan_t |
Enumerations | |
enum | ael_priority_type { AEL_APPCALL, AEL_CONTROL1, AEL_FOR_CONTROL, AEL_IF_CONTROL, AEL_IFTIME_CONTROL, AEL_RAND_CONTROL, AEL_LABEL, AEL_RETURN } |
Functions | |
struct pval * | ael2_parse (char *fname, int *errs) |
void | ael2_print (char *fname, pval *tree) |
void | ael2_semantic_check (pval *item, int *errs, int *warns, int *notes) |
void | destroy_pval (pval *item) |
pval * | linku1 (pval *head, pval *tail) |
pval * | npval (pvaltype type, int first_line, int last_line, int first_column, int last_column) |
Variables | |
char * | prev_word |
Structures for AEL - the Asterisk extension language.
Definition in file ael_structs.h.
#define QUAD_MAX (0x7fffffffffffffffLL) |
Definition at line 54 of file ael_structs.h.
#define QUAD_MIN (-0x7fffffffffffffffLL-1) |
Definition at line 51 of file ael_structs.h.
Referenced by chk_div(), and chk_minus().
typedef void* yyscan_t |
Definition at line 71 of file ael_structs.h.
enum ael_priority_type |
AEL_APPCALL | |
AEL_CONTROL1 | |
AEL_FOR_CONTROL | |
AEL_IF_CONTROL | |
AEL_IFTIME_CONTROL | |
AEL_RAND_CONTROL | |
AEL_LABEL | |
AEL_RETURN |
Definition at line 84 of file ael_structs.h.
struct pval* ael2_parse | ( | char * | fname, | |
int * | errs | |||
) | [read] |
Referenced by pbx_load_module().
void ael2_print | ( | char * | fname, | |
pval * | tree | |||
) |
Definition at line 384 of file pval.c.
References ast_log(), LOG_ERROR, and print_pval_list().
00385 { 00386 FILE *fin = fopen(fname,"w"); 00387 if ( !fin ) { 00388 ast_log(LOG_ERROR, "Couldn't open %s for writing.\n", fname); 00389 return; 00390 } 00391 print_pval_list(fin, tree, 0); 00392 fclose(fin); 00393 }
void ael2_semantic_check | ( | pval * | item, | |
int * | errs, | |||
int * | warns, | |||
int * | notes | |||
) |
Definition at line 2892 of file pval.c.
References ast_alloca, ast_config_AST_VAR_DIR, check_context_names(), and check_pval().
Referenced by pbx_load_module().
02893 { 02894 02895 #ifdef AAL_ARGCHECK 02896 int argapp_errs =0; 02897 char *rfilename; 02898 #endif 02899 struct argapp *apps=0; 02900 02901 if (!item) 02902 return; /* don't check an empty tree */ 02903 #ifdef AAL_ARGCHECK 02904 rfilename = ast_alloca(10 + strlen(ast_config_AST_VAR_DIR)); 02905 sprintf(rfilename, "%s/applist", ast_config_AST_VAR_DIR); 02906 02907 apps = argdesc_parse(rfilename, &argapp_errs); /* giveth */ 02908 #endif 02909 current_db = item; 02910 errs = warns = notes = 0; 02911 02912 check_context_names(); 02913 check_pval(item, apps, 0); 02914 02915 #ifdef AAL_ARGCHECK 02916 argdesc_destroy(apps); /* taketh away */ 02917 #endif 02918 current_db = 0; 02919 02920 *arg_errs = errs; 02921 *arg_warns = warns; 02922 *arg_notes = notes; 02923 }
void destroy_pval | ( | pval * | item | ) |
Definition at line 4979 of file pval.c.
Referenced by destroy_pval_item(), pbx_load_module(), yydestruct(), and yyparse().
04980 { 04981 pval *i,*nxt; 04982 04983 for (i=item; i; i=nxt) { 04984 nxt = i->next; 04985 04986 destroy_pval_item(i); 04987 } 04988 }
Definition at line 5926 of file pval.c.
Referenced by pvalAppCallAddArg(), pvalCasePatDefAddStatement(), pvalContextAddStatement(), pvalESwitchesAddSwitch(), pvalGlobalsAddStatement(), pvalIncludesAddInclude(), pvalIncludesAddIncludeWithTimeConstraints(), pvalMacroAddArg(), pvalMacroAddStatement(), pvalMacroCallAddArg(), pvalStatementBlockAddStatement(), pvalSwitchAddCase(), pvalSwitchesAddSwitch(), pvalTopLevAddObject(), and yyparse().
05927 { 05928 if (!head) 05929 return tail; 05930 if (tail) { 05931 if (!head->next) { 05932 head->next = tail; 05933 } else { 05934 head->u1_last->next = tail; 05935 } 05936 head->u1_last = tail; 05937 tail->prev = head; /* the dad link only points to containers */ 05938 } 05939 return head; 05940 }
struct pval * npval | ( | pvaltype | type, | |
int | first_line, | |||
int | last_line, | |||
int | first_column, | |||
int | last_column | |||
) | [read] |
Definition at line 3966 of file ael.tab.c.
References calloc, pval::endcol, pval::endline, pval::filename, S_OR, pval::startcol, pval::startline, strdup, and pval::type.
char* prev_word |
Definition at line 874 of file ael_lex.c.
Referenced by yydestruct(), and yyparse().