Skip to content

Commit 434f716

Browse files
committed
Updated 7800basic to v0.30
1 parent e64c273 commit 434f716

File tree

81 files changed

+1707
-58
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

81 files changed

+1707
-58
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions

README.md

Lines changed: 5 additions & 5 deletions

hovers/7800basic.md

Lines changed: 39 additions & 0 deletions

out/bin/compilers/7800basic/7800bas.bat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
@echo off
22
if X"%bas7800dir%" == X goto nobasic
33
:tryanyway
4-
7800preprocess <"%~f1" | 7800basic.exe -i "%bas7800dir%"
4+
7800preprocess <"%~f1" | 7800basic.exe -i "%bas7800dir%" -b "%1"
55
if errorlevel 1 goto basicerror
66
if X%2 == X-O goto optimize
77
7800postprocess -i "%bas7800dir%" > "%~f1.asm"

out/bin/compilers/7800basic/7800bas.c

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
#include <math.h>
1010

1111
char stdoutfilename[256];
12+
char backupname[256];
1213
FILE *stdoutfilepointer;
1314

1415
extern int currentdmahole;
@@ -22,7 +23,7 @@ extern char currentcharset[256];
2223
extern int graphicsdatawidth[16];
2324
extern char charactersetchars[257];
2425

25-
#define BASIC_VERSION_INFO "7800basic v0.29"
26+
#define BASIC_VERSION_INFO "7800basic v0.30"
2627

2728
int main (int argc, char *argv[])
2829
{
@@ -47,14 +48,18 @@ int main (int argc, char *argv[])
4748
char mycode[500];
4849
int defi = 0;
4950
path = NULL;
51+
backupname[0]=0;
5052
// get command line arguments
51-
while ((i = getopt (argc, argv, "i:r:v")) != -1)
53+
while ((i = getopt (argc, argv, "i:b:r:v")) != -1)
5254
{
5355
switch (i)
5456
{
5557
case 'i':
5658
path = optarg;
5759
break;
60+
case 'b':
61+
strncpy(backupname,optarg,256);
62+
break;
5863
case 'r':
5964
filename = optarg;
6065
break;
@@ -280,9 +285,11 @@ int main (int argc, char *argv[])
280285

281286
printf (" \n\n");
282287

288+
283289
header_write (header, filename);
284290
create_includes (includes_file);
285291
fprintf (stderr, "7800basic compilation complete.\n");
286292
freemem (deallocate_mem);
293+
lastrites();
287294
return 0;
288295
}
8.08 KB
Binary file not shown.
4.61 KB
Binary file not shown.
4.53 KB
Binary file not shown.
4.81 KB
Binary file not shown.
4.61 KB
Binary file not shown.

0 commit comments

Comments
 (0)