Fixed issue with trailing whitespace
This commit is contained in:
parent
9f8d78c9ec
commit
8431ac66f6
|
@ -115,6 +115,7 @@ file_import(char *path, char *ptr)
|
||||||
if(last == ')' && !spacer(c)) *ptr++ = ' ';
|
if(last == ')' && !spacer(c)) *ptr++ = ' ';
|
||||||
*ptr++ = last = c;
|
*ptr++ = last = c;
|
||||||
}
|
}
|
||||||
|
while(*(--ptr) <= ' ') *ptr = 0;
|
||||||
fclose(f);
|
fclose(f);
|
||||||
if(pr) fprintf(stderr, "Modal program imbalanced.\n");
|
if(pr) fprintf(stderr, "Modal program imbalanced.\n");
|
||||||
return ptr;
|
return ptr;
|
||||||
|
@ -338,7 +339,7 @@ main(int argc, char **argv)
|
||||||
return !printf("usage: modal [-vqn] source.modal\n");
|
return !printf("usage: modal [-vqn] source.modal\n");
|
||||||
for(i = 1; i < argc && *argv[i] == '-'; i++) {
|
for(i = 1; i < argc && *argv[i] == '-'; i++) {
|
||||||
switch(argv[i][1]) {
|
switch(argv[i][1]) {
|
||||||
case 'v': /* version */ return !printf("Modal Interpreter, 21 May 2024.\n");
|
case 'v': /* version */ return !printf("Modal Interpreter, 24 May 2024.\n");
|
||||||
case 'q': /* quiet */ quiet = 1; break;
|
case 'q': /* quiet */ quiet = 1; break;
|
||||||
case 'p': /* debug */ debug = 1; break;
|
case 'p': /* debug */ debug = 1; break;
|
||||||
case 'a': /* access */ access = 1; break;
|
case 'a': /* access */ access = 1; break;
|
||||||
|
|
Loading…
Reference in New Issue