|★ APPLICATIONS ★ PROGRAMMATION ★ PASCAL COMPILER ROM ★|
|Pascal Compiler ROM|Amstrad Computer User)||Applications Programmation|
How much can a language be cut down and still bear the name of the original? Jeff Walker looks at an implementation of Pascal which has gone too far
A FEW days later, after the nice man at the other end had made sure the CPC user's cheque was sitting snugly in his cosy bank account, the Pascal ROM arrived.
Computer languages don't come cheap; £40 is usually the lowest price around, so this particular CPC user was a still a little sceptical of a £20 Pascal especially one on rom, even as he was opening the small, plain brown package it arrived in.
The first thing to check out when buying a computer language is the documentation. Nobody expects a comprehensive tutorial on the language, but a clear and concise explanation of the implementation is imperative. You would at least expect a list of all the built-in functions and reserved words, with some examples of how each works.
After I had picked out the staples, sorted the pages into their correct order, and restapled them together (wasn't I lucky!I, the documentation for this Pascal ROM consisted of a slim. 24-page, photocopied booklet.
The first half of the booklet informs you of some of the less severe limitations of the program, and attempts to teach you the basics of Pascal programming - something more revered authors have written 300 page books about - and the second half is given over to page upon page of undocumented, confusing, and, in places, smudged listings.
After reading the section About Pascal I was left wondering where the documentation about all the other Pascal reserved words was. Only slowly did it dawn on me that this version supports less than half of the functions you would expect from a "standard" Pascal.
Pascal is a strongly "typed" language. In Basic we have four types: INTEGER, REAL (floating point), STRING, and ARRAY. In Pascal there are more. For a start there should be things called RECORDS and SETs, and. along with INTEGER and REAL, there should be a CHAR type, a BOOLEAN type, and maybe even a STRING type.
Pascal Compiler ROM has only one type: INTEGER. It seems you can have CHAR types and STRING types, but you must declare them as type INTEGER (?).
The lack of a BOOLEAN type is a serious omission. Because of this, the Pascal identifiers TRUE and FALSE are missing too. Boolean functions are among the 10 most useful things in the universe when it comes to ease of programming and debugging.
The lack of a REAL type means there is no floating point arithmetic available, and this rules out the standard Pascal functions like SIN, COS, SQRr EXP, and any other function that may return a floating point number.
The lack of RECORDS and SETs makes this implementation little more than an expensive toy. After all, Pascal was invented so that programmers could structure their data in a clear and logical way. RECORDS and SETs are the data structures that enable you to do this, but not with this effort from John Morrison.
Pascal Compiler ROM supports ARRAYs, but only single-dimensioned ones. John Morrison says this "is not much of a handicap". Maybe not, but it's one hell of a restriction.
Input/Output is controlled solely by the READ/WRITE functions. Strangely, the READLN and WRITELN functions have been omitted. This alone will cause enormous problems when trying to convert standard Pascal code from the books you will no doubt buy or borrow in order to learn the language.
There are no built-in functions for reading/writing to file from within a program. Library procedures are provided for saving and loading Binary files. Routines for Ascii files would have been more useful.
Other important features of standard Pascals that this version omits are pointers, a FORWARD facility for procedures and functions, and facilities for compiling long source code files from disc.
Pascal Compiler ROM cannot compile from ordinary text files, only files saved by its SAVE facility. This forces you to use John Morrison's awful built-in text editor.
This implementation of the Pascal programming language is useless to beginners and experts alike because it is so far removed from the agreed standard. If you learn this version, you'll have to start all over again when you get hold of the real thing.
I've got nothing good to say about this piece of "software". Do yourself an enormous favour and steer well clear of John Morrison's Pascal Compiler WOM. No that's not a misprint.Jt stands for Waste Of Money.