Changeset 7874d77
- Timestamp:
- Aug 11, 2020, 5:33:21 PM (4 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- cd9ee44
- Parents:
- 8e516fd
- Location:
- libcfa
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/prelude/bootloader.cf
r8e516fd r7874d77 1 1 extern "C" { static inline int invoke_main(int argc, char* argv[], char* envp[]); } 2 int cfa_args_argc; 3 char ** cfa_args_argv; 4 char ** cfa_args_envp; 2 5 3 6 int main(int argc, char* argv[], char* envp[]) { 7 cfa_args_argc = argc; 8 cfa_args_argv = argv; 9 cfa_args_envp = envp; 4 10 return invoke_main(argc, argv, envp); 5 11 } -
libcfa/src/parseargs.cfa
r8e516fd r7874d77 24 24 #include "limits.hfa" 25 25 26 extern int cfa_args_argc; 27 extern char ** cfa_args_argv; 28 extern char ** cfa_args_envp; 29 26 30 void printopt(FILE * out, int width, int max, char sn, const char * ln, const char * help) { 27 31 int hwidth = max - (11 + width); … … 34 38 fprintf(out, "%*s%.*s\n", width + 11, "", hwidth, help); 35 39 } 40 } 41 42 void parse_args( cfa_option options[], size_t opt_count, const char * usage, char ** & left ) { 43 parse_args(cfa_args_argc, cfa_args_argv, options, opt_count, usage, left ); 36 44 } 37 45 -
libcfa/src/parseargs.hfa
r8e516fd r7874d77 31 31 } 32 32 33 void parse_args( cfa_option options[], size_t opt_count, const char * usage, char ** & left ); 33 34 void parse_args( int argc, char * argv[], cfa_option options[], size_t opt_count, const char * usage, char ** & left ); 34 35
Note: See TracChangeset
for help on using the changeset viewer.