home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c
- Path: sparky!uunet!noc.near.net!mv!siia!wje
- From: wje@siia.mv.com (Bill Ezell)
- Subject: Re: Conversion of BASIC code to "C"
- Message-ID: <1993Jan11.123129.7416@siia.mv.com>
- Organization: Software Innovations, Inc.
- References: <1993Jan8.183821.20711@adobe.com> <1993Jan10.131651.1@csbina.csubak.edu>
- Date: Mon, 11 Jan 93 12:31:29 GMT
- Lines: 28
-
- >In article <1993Jan8.183821.20711@adobe.com>, (Scott Sivi) writes:
- >> Does there exist a method or application by which BASIC files can be
- >> converted
- >> to "C".
- >You probably couldn't even do it by hand unless the BASIC program was
- >completely flowed and never used a GOTO! The way BASIC programmers spaghetti-
- >code programs, I doubt it's possible. (I'm assuming you won't use goto in C.
- >I wouldn't.)
-
- An absurd statement, of course. There are several commercially available
- Basic-to-C translators. Some are better than others. Given the enormous
- number of Basic variants out there, if you're not using a common and
- popular Basic, you might have trouble finding one.
- We have one for MS PDS Basic to C.
-
- As for never using a goto, there are quite good and practical reasons
- for using them. This isn't to say that they should be used with any
- regularity, but they can sometimes result in much more readable code.
- A prime example is getting to a common error point in a routine that
- has deep nesting of conditionals or other control constructs. Also,
- many machine-generated C programs use gotos. Ever looked at a yacc parser?
-
- wje@siia.mv.com
- --
- ------------------------------
- | Bill Ezell |
- | Software Innovations, Inc. |
- | wje@siia.mv.com |
-