Talk About Network



Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Basic Misc > Re: Interpreter...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 15 of 63 Topic 1431 of 1467
Post > Topic >>

Re: Interpreter for old basic programs from the line number era

by thomas.mertes@[EMAIL PROTECTED] Mar 6, 2008 at 12:05 PM

On 6 Mrz., 18:12, "Auric__" <not.my.r...@[EMAIL PROTECTED]
> wrote:
> On Wed, 05 Mar 2008 08:04:10 GMT,  wrote:
> > If you take a look at the description of bas7 at
>
> >http://seed7.sourceforge.net/scrshots/bas7.htm
>
> > you see that the primarily intend of Bas7 is to analyze spaghetti
> > code. Therefore it writes a log file while interpreting the BASIC
> > program.
>
> Analyze how? What exactly does it do, output a list of line numbers to
> the log? ...

The log file of a very small example program:

  100 PRINT "Hello, world!"
  105 IF I=0THEN 107ELSE 110
  107 IF I=1THEN 110ELSE 110
  110 INPUT "Press return to continue",a$

load_prog finished
100 PRINT "Hello, world!"
I is 0.0
105 IF -1.0 THEN - GOTO 107
I is 0.0
107 IF 0.0 THEN - SKIP LABEL
107 ELSE - GOTO 110
110 INPUT "Press return to continue"
110 INPUT A$ <- ""
END OF PROGRAM REACHED

As you can see: First you get the program listing and
then you get line numbers + statements + some information
like "SKIP LABEL". Every time a variable is accessed you
get a message like "I is 0.0". Here is a part from
another log:

640 IF -1.0 THEN - EXECUTE STATEMENTS IN LINE UNTIL "ELSE"
640 LET S=1.0
640 RETURN FROM "GOSUB 640" AT LINE 302
S is 1.0
303 IF -1.0 THEN - EXECUTE STATEMENTS IN LINE UNTIL "ELSE"
304 EXIT FOR
Y is 1.0
310 EMPTY FOR B=0.0 TO 1.0 STEP -1.0
313 CONTINUE AFTER NEXT
 ***** [314] RETURN - SOME FOR LOOPS WERE NOT LEFT
314 LEAVE THE FOR B LOOP AT LINE 301
314 LEAVE THE FOR A LOOP AT LINE 281
314 RETURN FROM "GOSUB 250" AT LINE 730
740 NEXT Y = 2.0 CONTINUE FOR
X is 1.0
Y is 2.0
A(1,2) is 2.0
730 IF -1.0 THEN - EXECUTE STATEMENTS IN LINE UNTIL "ELSE"
730 GOSUB 250
250 LOCATE 1,78
250 LOCATE ,,0
250 PRINT "$ ";

> ... (I'm not going to d/l it to find out -- I'm on v-e-e-e-e-e-r-y
> slow dial-up and most downloads are painful.)

The good message is: The download is only 987039 Bytes.
The bad message is: You have to compile it. The 987039 Bytes
consist of the Seed7 package seed7_05_20080302.tgz and is here:
http://sourceforge.net/project/showfiles.php?group_id=151126&package_id=167035
After you succeded with the compilation you can start Bas7 with:
../hi bas7 your_basic_program

Greetings Thomas Mertes

Seed7 Homepage:  http://seed7.sourceforge.net
Seed7 - The extensible programming language: User defined statements
and operators, abstract data types, templates without special
syntax, OO with interfaces and multiple dispatch, statically typed,
interpreted or compiled, portable, runs under linux/unix/windows.




 63 Posts in Topic:
Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-03 11:12:00 
Re: Interpreter for old basic programs from the line number era
Paul Bartlett <bartlet  2008-03-03 20:07:01 
Re: Interpreter for old basic programs from the line number era
rebel <me@[EMAIL PROTE  2008-03-04 10:16:31 
Re: Interpreter for old basic programs from the line number era
"R.Nicholson" &  2008-03-03 18:23:10 
Re: Interpreter for old basic programs from the line number era
rebel <me@[EMAIL PROTE  2008-03-05 10:44:45 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-08 01:56:45 
Re: Interpreter for old basic programs from the line number era
ArarghMail803NOSPAM@[EMAI  2008-03-08 15:47:56 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-04 00:05:17 
Re: Interpreter for old basic programs from the line number era
"R.Nicholson" &  2008-03-04 19:09:26 
Re: Interpreter for old basic programs from the line number era
Happy Trails <nomail@[  2008-03-04 22:46:12 
Re: Interpreter for old basic programs from the line number era
"R.Nicholson" &  2008-03-04 21:06:46 
Re: Interpreter for old basic programs from the line number era
Happy Trails <nomail@[  2008-03-05 11:07:24 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-05 00:04:10 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-06 17:12:03 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-06 12:05:46 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-07 17:12:49 
Re: Interpreter for old basic programs from the line number era
ArarghMail803NOSPAM@[EMAI  2008-03-07 13:38:51 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-07 23:58:56 
Re: Interpreter for old basic programs from the line number era
ArarghMail803NOSPAM@[EMAI  2008-03-07 18:53:19 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-10 17:46:12 
Re: Interpreter for old basic programs from the line number era
ArarghMail803NOSPAM@[EMAI  2008-03-10 18:17:41 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-11 17:01:43 
Re: Interpreter for old basic programs from the line number era
ArarghMail803NOSPAM@[EMAI  2008-03-11 17:43:05 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-12 17:35:00 
Re: Interpreter for old basic programs from the line number era
ArarghMail803NOSPAM@[EMAI  2008-03-12 14:22:49 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-13 15:10:08 
Re: Interpreter for old basic programs from the line number era
ArarghMail803NOSPAM@[EMAI  2008-03-13 19:36:55 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-14 17:26:15 
Re: Interpreter for old basic programs from the line number era
ArarghMail803NOSPAM@[EMAI  2008-03-14 18:01:00 
Re: Interpreter for old basic programs from the line number era
Guy Macon <http://www.  2008-03-06 20:58:28 
Re: Interpreter for old basic programs from the line number era
"Tom Lake" <  2008-03-06 16:02:16 
Re: Interpreter for old basic programs from the line number era
Guy Macon <http://www.  2008-03-06 21:26:33 
Re: Interpreter for old basic programs from the line number era
"Judson McClendon&qu  2008-03-06 15:25:02 
Re: Interpreter for old basic programs from the line number era
ArarghMail803NOSPAM@[EMAI  2008-03-06 16:58:58 
Re: Interpreter for old basic programs from the line number era
Vic Drastik <user@[EMA  2008-03-08 23:33:53 
Re: Interpreter for old basic programs from the line number era
Vic Drastik <user@[EMA  2008-03-08 23:51:54 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-06 15:16:17 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-08 01:20:26 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-10 17:51:46 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-11 17:21:41 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-11 17:23:33 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-08 01:38:33 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-11 12:57:35 
Re: Interpreter for old basic programs from the line number era
"Auric__" <n  2008-03-12 18:06:43 
Re: Interpreter for old basic programs from the line number era
Warren Gay <snark@[EMA  2008-03-13 15:19:22 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-13 03:41:59 
Re: Interpreter for old basic programs from the line number era
Warren Gay <snark@[EMA  2008-03-13 15:36:05 
Re: Interpreter for old basic programs from the line number era
Thomas Dickey <dickey@  2008-03-14 11:11:41 
Re: Interpreter for old basic programs from the line number era
Charmed Snark <snark@[  2008-03-14 15:28:29 
Re: Interpreter for old basic programs from the line number era
Thomas Dickey <dickey@  2008-03-14 22:37:27 
Re: Interpreter for old basic programs from the line number era
Charmed Snark <snark@[  2008-03-15 04:15:36 
Re: Interpreter for old basic programs from the line number era
Thomas Dickey <dickey@  2008-03-16 13:10:27 
Re: Interpreter for old basic programs from the line number era
Thomas Dickey <dickey@  2008-03-14 16:03:56 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-14 08:41:36 
Re: Interpreter for old basic programs from the line number era
Charmed Snark <snark@[  2008-03-14 15:57:50 
Re: Interpreter for old basic programs from the line number era
Eric <englere_geo@[EMA  2008-03-18 09:11:26 
Re: Interpreter for old basic programs from the line number era
Charmed Snark <snark@[  2008-03-18 19:52:03 
Re: Interpreter for old basic programs from the line number era
winston19842005 <bjjly  2008-03-18 18:18:44 
Re: Interpreter for old basic programs from the line number era
Eric <englere_geo@[EMA  2008-03-18 20:41:12 
Re: Interpreter for old basic programs from the line number era
"winston19842005@[EM  2008-03-18 22:13:40 
Re: Interpreter for old basic programs from the line number era
Charmed Snark <snark@[  2008-03-19 15:32:27 
Re: Interpreter for old basic programs from the line number era
thomas.mertes@[EMAIL PROT  2008-03-19 12:35:28 
Re: Interpreter for old basic programs from the line number era
Derek <derekrss@[EMAIL  2008-03-19 22:37:05 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Thu May 22 14:16:48 CDT 2008.