Drobe :: The archives
About Drobe | Contact | RSS | Twitter | Tech docs | Downloads | BBC Micro

Castle push BASIC compiler

By Chris Williams. Published: 31st Aug 2005, 15:43:26 | Permalink | Printable

Basically already available

Castle have inroduced a new software development CD for BASIC coders. The disc contains the ABC BASIC compiler and the BASIC and PRM manuals, as found on the already available C/C++ compiler package.

The ABC tool compiles software written in BASIC into executable machine code, bypassing the BASIC module that would otherwise interpret the software on the fly. Castle's Iyonix Update Watcher is built by ABC, for instance.


ABC compiler CD

Previous: Software news
Next: CJE to raise cash for hospices


Viewing threaded comments | View comments unthreaded, listed by date | Skip to the end

This strikes me as a sensible move. There must be a lot of BASIC coders out there who don't have the need for the whole C/C++ suite, but who would be interested in just the BASIC compiler.

My only reservation is that in such a small market, Castle might get a better return if their development tools were included with the machine.

Does anyone have any info on how the compiled BASIC produced compares to interpreted BASIC? Is there anything ABC can't do (e.g. EVAL?)?

 is a RISC OS Userflypig on 31/8/05 3:52PM
[ Reply | Permalink | Report ]

Yes, I'd be interested in knowing what the benefits (and problems?) of "complied" basic are. The PRMs and Basic manual are certainly worthwhile for any Basic RISC OS programmer though.

 is a RISC OS Useradamr on 31/8/05 4:39PM
[ Reply | Permalink | Report ]

One major difference between interpreted BASIC and how ABC behaves is in variable scoping. A variable local to a procedure is not visible in other procedures called inside it. Which means most of my code won't compile without substantial work. Other differences include no multiple UNTILs, NEXTs or ENDWHILEs, no local arrays, no array operations, no EVAL, no SUM, no WIDTH, and various restrictions on indirection operators.

All the above applies to ABC 4.12, as supplied with the C Suite. I don't know if the new version has any improvements.

 is a RISC OS Userchrist on 31/8/05 4:50PM
[ Reply | Permalink | Report ]

The lack of EVAL and the variable scooping would certainly make a lot of work for me. I would be very interested to see the difference between a compressed program and a compiled one.

 is a RISC OS Userdemondb on 31/8/05 5:15PM
[ Reply | Permalink | Report ]

EVAL is basically uncompilable. Unless you just call BASIC's EVAL of course.

What difference are you looking for demondb, speed or size? I can't actually supply an answer, but doesn't the ABC compiler have a module it needs?

 is a RISC OS UserLoris on 31/8/05 5:45PM
[ Reply | Permalink | Report ]

I'm for one, very pleased at this release, and can only agree with flypig that it is disappointing that the development tools are not included.

Still at least I can now re write my Passwords program and release it with the encryption routines well hidden.

Nice one Castle. you've saved me about 150 UKP! :0))

 is a RISC OS User2307 on 31/8/05 9:44PM
[ Reply | Permalink | Report ]

We asked Paul at the RISCOS-Expo (NL), why not releasing the ABC-Compiler alone. He told us, that he did not expect a big interest in that and that the manual-file was lost. One german user (Gregor Gelissen) explained, that he was willing to make a new file from a old paper-hardcopy. So if there is a manual-file for the ABC-Compiler on the CD, we have to thank Gregor, who made it possible. Anyway - nice to see, that user-suggestions are taken serious. Well done Castle!

 is a RISC OS UserMoAco on 31/8/05 11:12PM
[ Reply | Permalink | Report ]

Has the compiler been updated at all from the version supplied with C/C++? (4.14 is the one I got, I think, but I don't have it in front of me.)

 is a RISC OS Userben on 1/9/05 9:00AM
[ Reply | Permalink | Report ]

MoAco: I'm fairly sure that you asked Jack, not Paul ;-)

 is a RISC OS Userhubersn on 1/9/05 9:53AM
[ Reply | Permalink | Report ]


How could the lack of the manual file have anything to do with the ability to release a stand-alone version of the ABC compiler? The compiler is released on the Development Tools CD including a manual file. Either that file is adequate, then the same file can be used for a stand-alone release or it is not, in which case the BASIC compiler could not have been released on the Development Tools CD either.

 is a RISC OS Userwuerthne on 1/9/05 11:28AM
[ Reply | Permalink | Report ]

"One major difference between interpreted BASIC and how ABC behaves is in variable scoping. A variable local to a procedure is not visible in other procedures called inside it. Which means most of my code won't compile without substantial work"

Translation: "My code is hideous".

 is a RISC OS UserChimpy on 1/9/05 12:48PM
[ Reply | Permalink | Report ]

In rely to chimpy

Are you sure you understand what christ is saying ?

It seems logical to me that once a variable is delared local to a procedure it should also be visable to any (sub)procedure called from within that procedure, unless it is declared as local in the (sub)procedure, of course - although that would be coding to obscure rather than clarify.

Maybe I've just got so used to BBC BASIC that what to others seem quirks seem to promote ease of coding to me.

The lack of EVAL is the major reason I'd avoid compiling BBC BASIC. It flys like the wind anyway. There is always machine code if speed is really an issue.

 is a RISC OS Usermartin on 1/9/05 1:03PM
[ Reply | Permalink | Report ]

In reply to Martin:

The difference is between what is called static and dynamic binding. In static binding, the scope of a variable is the procedure in which it is declared and any procedures declared locally inside this. In dynamic binding, a variable is created when its declaratiion is seen/executed and removed when execution returns from the procedure in which it is declared. This means that the variable is visible in all procedures called from this procedure, even if they are not declared locally therein.

Static binding is used in almost all compiled languages while dynamic binding is mostly used in interpreted languages, though far from all of these.

Dynamic binding makes static (i.e., compile-time) type checking difficult, so languages with static type checking generally use static binding. It is also easier for a programmer to see which variable declaration a use refers to if you use static binding.

The main advantages of dynamic binding are: It allows a slightly simpler imlementation in an interpreter and it allows you to effectively give parameters to a procedure even if there is no explicit parameter-passing mechanism (without resorting to global variables).

 is a RISC OS Usertorbenm on 1/9/05 2:45PM
[ Reply | Permalink | Report ]

I suppose expecting people to write technically good code in BASIC is like asking people to do calligraphy with a set of fat blunt crayons. Oh well :)

 is a RISC OS UserChimpy on 1/9/05 3:00PM
[ Reply | Permalink | Report ]


... you are fairly right :-)


When we asked Jack, if it is possible to release the ABC-Compiler alone ... we pointed out, that it is uninteresting for a pure-basic-coder, to buy the whole development CD only to receive the compiler.

Jack seems not convinced of this idea because he belived, that there is not much interest in a "ABC-only CD" - he was surprised, that all 4 of us were very interested :-). Jack than mentioned, that there is a second problem: some manual / docs (don t know exactly wich) have been lost and he would not release a "unsupported" product. Gregor explained, that he has a paper-version of the missing manual and is willing to create a file of it ... so Jack finally changed his opinion. I do not know exactly if Gregor really made this file and if it is different to the file you mentioned. I just was happy to see, that Jack picked up our idea.

 is a RISC OS UserMoAco on 1/9/05 3:10PM
[ Reply | Permalink | Report ]

The manual included with the version in the C/C++ Tools package describes itself as "this Release Note as a highly abridged form of the 1991 manual plus additions". It comes as a PDF.

I write little BASIC these days and haven't used the compiler beyond checking that it runs but the information in the "Release Note" looked adequate to me. Keywords listed as not working in the compiler are: APPEND, CHAIN, LOAD, SAVE, COUNT, EVAL, SUM, WIDTH (only EVAL looks like a big loss to me and, as has already been said, it's simply not possible to compile it).

Other restrictions seem mainly to be around having only one NEXT per FOR etc, which hopefully people do anyway (sorry, C programmer here is not allowed to do otherwise so can't think in those terms).

On a brighter note, there are some minor enhancements plus some bug-fixes listed for versions produced since Oak's last release (and it's been 32-bitted, of course).

 is a RISC OS UserTonyStill on 1/9/05 11:07PM
[ Reply | Permalink | Report ]

Please login before posting a comment. Use the form on the right to do so or create a free account.

Search the archives

Today's featured article

  • Archive booklets review part three
    Ovation Pro, VirtualRiscPC and hardware tips
     Discuss this. Published: 4 Feb 2006

  • Random article

  • News in brief
    XScale hacking, showcasing RISC OS, a bunker of software updates and more
     12 comments, latest by Spriteman on 20/2/06 12:47PM. Published: 16 Feb 2006

  • Useful links

    News and media:

    Top developers:
    RISCOS LtdRISC OS OpenMW SoftwareR-CompAdvantage SixVirtualAcorn

    CJE MicrosAPDLCastlea4X-AmpleLiquid SiliconWebmonster


    RISCOS.org.ukRISCOS.orgRISCOS.infoFilebaseChris Why's Acorn/RISC OS collectionNetSurf

    Non-RISC OS:
    The RegisterThe InquirerApple InsiderBBC NewsSky NewsGoogle Newsxkcddiodesign

    © 1999-2009 The Drobe Team. Some rights reserved, click here for more information
    Powered by MiniDrobeCMS, based on J4U | Statistics
    "Thanks for the unkind comments. Why are the young such ****s? "
    Page generated in 0.1641 seconds.