home *** CD-ROM | disk | FTP | other *** search
- CBASIC in General
- CBASIC2 Compile-Time Toggled Options
- XREF Cross Reference Facility
- Compiler Error Messages
- Run-Time Error Messages -- Warnings
- Run-Time Error Messages -- Error Codes
- CBASIC2 Reserved Words
- CBASIC2 Expression Hierarchy
- CBASIC2 Predefined Functions
- :CBASIC2: CBASIC in General
-
- CBASI├á i≤á ß compile≥ BASI├ whicΦ ma∙ bσ executeΣ oε an∙ flopp∙á disδ ì
- baseΣá CP/═ systeφ havinτ a⌠ leas⌠ 20╦ byte≤ oµ memory«á Iε orde≥ t∩á makσ ì
- thσá bes⌠ usσ oµ thσ powe≥ anΣ flexibilit∙ oµ CBASIC¼á ß dua∞á flopp∙á disδ ì
- systeφá anΣ a⌠ leas⌠ 32╦ oµ memor∙ i≤ recommended«á Iµ CBASI├ i≤á executeΣ ì
- in a system smaller than 20K, a CP/M LOAD ERROR may occur.
-
- Thσ CBASI├ systeφ consist≤ oµ tw∩ program≤ -- CBASI├ anΣ CRUN« CBASI├ ì
- i≤ thσ compiler¼á anΣ CRU╬ i≤ thσ run-timσ intepreter« Iε ß typica∞ CBASI├ ì
- session¼á thσ use≥ wil∞ writσ thσ prograφ usinτ ED¼ compilσ i⌠ usinτ CBASI├ ì
- (with the $B option to suppress listing), and run it using CRUN.
-
- Refer to the 84-page CBASIC manual --
-
- C B A S I C
- A Commercially Oriented
- Compiler/Interpreter BASIC
- Language Facility for
- CP/M Systems
-
- February 17, 1978
-
- CBASIC▓ i≤ aε upward-compatablσ (iε term≤ oµ sourcσ code⌐ extensioε oµ ì
- thσá origina∞ CBASIC«á Iε additioε t∩ al∞ oµ thσ feature≤ oµ thσá origina∞ ì
- CBASIC, CBASIC2 adds the following:
- 1. Integer variables
- 2. Chaining with common variables
- 3. Additional pre-defined functions
- 4. Cross Reference capability
- Notσá tha⌠á CBASIC▓ i≤ upward-compatablσ witΦ CBASI├ onl∙ iε term≤á oµ ì
- thσ sourcσ codσ files«á Aε IN╘ filσ createΣ unde≥ CBASI├ wil∞ no⌠á executσ ì
- with the Version 2 Run-Time Monitor (CRUN2).
- For further information, refer to the 100-page reference manual --
-
- C B A S I C
- A Commercially Oriented
- Compiler/Interpreter BASIC
- Language Facility for
- CP/M Systems
- Version 2
-
- May 1, 1979
- :CBASIC2: CBASIC2 Compile-Time Toggled Options
-
- Compile≥á toggle≤á arσ ß serie≤ oµ switche≤ tha⌠ caε bσ se⌠á wheεá thσ ì
- compile≥á i≤á executed«á Thσ toggle≤ arσ se⌠ b∙ typinτ ßá dollar-sigεá ($⌐ ì
- followeΣá b∙á thσ lette≥ designation≤ oµ thσ desireΣ toggle≤á startinτá onσ ì
- spacσ o≥ morσ afte≥ thσ prograφ namσ oε thσ commanΣ line« Toggle≤ ma∙ onl∙ ì
- be set for the compiler.
-
- Examples of compiler toggles and invocation forms are --
- CBAS2 INVENTRY $BGF
- B:CBAS2 A:COMPARE $GEC
- CBAS2 PAYROLL $B
- CBAS2 B:VALIDATE $E
-
- CBASIC Compiler Toggles
-
- TOGGL┼ B║ Suppresse≤ thσ listinτ oµ thσ prograφ oε thσ consolσ durinτ ì
- compilation«á Iµ aε erro≥ i≤ detected¼á thσ sourcσ linσ witΦ thσ erro≥ anΣ ì
- thσá erro≥ messagσ wil∞ bσ printeΣ eveε iµ Togglσ ┬ i≤ set«á Togglσ ┬ doe≤ ì
- not affect listing to the printer (Toggle F) or disk file (Toggle G).
- Toggle B is initially off.
-
- TOGGL┼á C║á Suppresse≤ thσ generatioε oµ aε IN╘ file«á Engaginτá thi≤ ì
- togglσá wil∞á providσ ß synta° checδ withou⌠ thσ overheaΣá oµá writinτá thσ ì
- intermediatσ file.
- Toggle C is initially off.
-
- TOGGL┼ D║ Suppresse≤ translatioε oµ lower-casσ letter≤ t∩ upper-case« ì
- Fo≥ example¼á iµ Togglσ ─ i≤ on¼á 'AMTº wil∞ no⌠ refe≥ t∩ thσ samσ variablσ ì
- as 'amt'.
- Toggle D is initially off.
-
-
- TOGGL┼á E║ Cause≤ thσ run-timσ prograφ (CRUN2⌐ t∩ accompan∙ an∙ erro≥ ì
- message≤ witΦ thσ CBASI├ linσ numbe≥ iε whicΦ thσ erro≥ occurred« Togglσ ┼ ì
- mus⌠ bσ se⌠ iε orde≥ fo≥ thσ TRAC┼ optioε (seσ sectioε 13.┤ oµ thσá manual⌐ ì
- t∩ work.
- Toggle E is initially off.
-
- TOGGL┼á F║á Cause≤ thσ compile≥ outpu⌠ listinτ t∩ bσ printeΣá oεá thσ ì
- LST: device in addition to the system console.
- Toggle F is initially off.
-
- TOGGL┼á G║á Cause≤á thσá compile≥ outpu⌠ listinτá t∩á bσá writteεá t∩ ì
- diskette«á Thσá filσ containinτ thσ compile≥ listinτ ha≤ thσ samσ namσá a≤ ì
- the .BAS file, but its type is .LST.
- Normall∙á thσ disδ listinτ wil∞ bσ placeΣ oε thσ samσ sourcσ drivσá a≤ ì
- thσá sourcσ file«á Thσ operato≥ ma∙ selec⌠ anothe≥ drivσ b∙ specifyinτ thσ ì
- desired drive, enclosed in parens, following the G toggle; for example,
- CBAS2 B:TAX $G(A:)
- extracts the source from drive B: and sends the listing to drive A:.
- Toggle G is initially off.
- :CBASIC2: XREF Cross Reference Facility
- Thσá XREF.CO═á Cros≤ Referencσ utilit∙ prograφ produce≤ ßá filσá whicΦ ì
- contain≤ aε alphabetizeΣ lis⌠ oµ al∞ identifier≤ useΣ iε ß CBASI├á program« ì
- Thσ usagσ oµ thσ identifie≥ (function¼á parameter¼á o≥ global⌐ i≤ provided¼ ì
- a≤ wel∞ a≤ ß lis⌠ oµ eacΦ linσ iε whicΦ tha⌠ identifie≥ i≤ used«á Thσ filσ ì
- createΣá ha≤á thσ samσ namσ a≤ thσ CBASI├ sourcσ filσ anΣ i≤ oµá typσá XRF« ì
- The standard output is 132 columns wide.
- The following command is used to invoke XREF --
-
- XREF <filename> [disk ref] [$<toggles>] ['title']
-
- Iµ thσ disδ referencσ i≤ specified¼á i⌠ instruct≤ XRE╞ a≤ t∩ wha⌠ disδ ì
- to place the output on.
- The toggles are described on the next display.
- Thσá optiona∞ titlσ fielΣ mus⌠ bσ thσ las⌠ fielΣ iε thσ commanΣá line« ì
- Al∞ character≤ followinτ thσ firs⌠ apostrophσ oε thσ commanΣ linσ u≡ t∩ thσ ì
- seconΣá apostrophσ o≥ unti∞ thσ enΣ oµ thσ commanΣ linσ becomσá thσá title« ì
- Thσá titlσ i≤ truncateΣ t∩ 3░ character≤ iµ thσ listinτ i≤ 13▓ column≤ widσ ì
- and 20 characters if the D toggle (80 column listing) is specified.
-
-
- XREF Toggles
-
- Togglσá A║ Cause≤ thσ listinτ t∩ bσ otpu⌠ t∩ thσ lis⌠ devicσ a≤á wel∞ ì
- as the disk file.
-
- Togglσá B║á Suppresse≤ outpu⌠ t∩ thσ disk«á Iµ onl∙ thσ ┬ togglσá i≤ ì
- specified, no output is produced.
-
- Togglσá C║á Suppresse≤ outpu⌠ t∩ thσ disδ anΣ permit≤ outpu⌠á t∩á thσ ì
- list device; same as A and B combined.
-
- Toggle D: Causes output to be 80 columns wide instead of 132.
-
- Toggle E: Produces output with only the identifiers and their usage.
-
-
- Fo≥ example¼á thσ followinτ commanΣ produce≤ ß cros≤ referencσ listinτ ì
- on the list device which is 80 columns wide --
-
- XREF PROG $CD
- :CBASIC: Compiler Error Messages
-
- Text Messages
-
- NO SOURCE FILE: <FILENAME>.BAS
- Thσá compile≥ coulΣ no⌠ locatσ ß sourcσ filσ useΣ iε eithe≥á ßá CBASI├ ì
- command or an INCLUDE directive.
-
- PROGRAM CONTAINS n UNMATCHED FOR STATEMENT(S)
- There are n FOR statements for which a NEXT could not be found.
-
- PROGRAM CONTAINS n UNMATCHED WHILE STATEMENT(S)
- There are n WHILE statements for which a WEND could not be found.
-
- WARNING: INVALID CHARACTER IGNORED
- Thσ previou≤ linσ contain≤ aε invaliΣ ASCI╔ character╗á thi≤ characte≥ ì
- is ignored by the compiler, and a question mark is printed in its place.
-
- OUT OF DISK SPACE
- Thσá compile≥á ha≤á ruε ou⌠ oµ disδ spacσ whilσá attemptinτá t∩á writσ ì
- either the INT or LST files.
-
- Text Messages (Con't)
-
- OUT OF DIRECTORY SPACE
- Thσá compile≥á ha≤ ruε ou⌠ oµ director∙ entrie≤á whilσá attemptinτá t∩ ì
- create or extend a file.
-
- DISK ERROR
- A disk error occurred while trying to read or write to a disk file.
-
- INCLUDE NESTING TOO DEEP NEAR LINE n
- Aεá includσá statemen⌠ nea≥ linσ ε iε thσ sourcσ prograφá exceed≤á thσ ì
- maximum level of nesting of source files.
-
-
- 2-Letter Error Codes
-
- BF -- Branch into Function
- A branch into a multiple line function from outside was attempted.
-
- BN -- Bad Number
- An invalid numeric constant was encountered.
-
- CE -- Close Error
- The intermediate (.INT) file could not be closed.
-
- CI -- Close Include
- An invalid file name in an %INCLUDE statement.
-
- CS -- COMMON Statement error
- ┴á COMMO╬ statemen⌠ whicΦ wa≤ no⌠ thσ firs⌠ statemen⌠ iεá thσá prograφ ì
- wa≤ detected.
-
- CV -- COMMON Variable error
- An improper reference to a subscripte variable in a COMMON statement.
-
- DE -- Disk Error
- A disk error occurred while trying to read the .BAS file.
-
- DF -- Disk Full
- Therσá wa≤ n∩ spacσ oε thσ disδ o≥ thσ disδ director∙ wa≤á full«á Thσ ì
- .INT file was not created.
-
- DL -- Duplicate Line number
- Thσ samσ linσ numbe≥ wa≤ useΣ oε tw∩ differen⌠ lines«á Othe≥ compile≥ ì
- error≤á ma∙á causσ ß D╠ erro≥ messagσ t∩ bσ printeΣ eveε iµ duplicatσá linσ ì
- numbers do not exist.
-
- DP -- Defined Previously
- A variable in a DIM statement was previously defined.
-
- EF -- Exponential Format
- ┴ numbe≥ iε exponentia∞ forma⌠ wa≤ inpu⌠ witΦ n∩ digit≤ followinτá thσ ì
- E.
-
- FA -- Function Attribute
- ┴á functioεá namσ appear≤ oε thσ lef⌠ sidσ oµ aε assignmen⌠á statemen⌠ ì
- but is not within that function.
-
- FD -- Function Definition
- ┴ functioε namσ tha⌠ ha≤ beeε previousl∙ defineΣ i≤ beinτ redefineΣ iε ì
- a DEF statement.
-
- FE -- FOR Error
- ┴á mixeΣ modσ expressioε exist≤ iε ß FO╥ statemen⌠ whicΦ thσá compile≥ ì
- cannot correct.
-
- FI -- FOR Index
- Aεá expressioε whicΦ i≤ no⌠ aε unsubscripteΣ numeriπ variablσ i≤ beinτ ì
- used as a FOR loop index.
-
- FN -- Function parameter Number
- A function reference contains an incorrect number of parameters.
-
- FP -- Function Parameter type
- ┴ functioε referencσ paramete≥ typσ doe≤ no⌠ matcΦ thσ paramete≥á typσ ì
- used in the function's DEF statement.
-
- FU -- Function Undefined
- A function has been referenced before it has been defined.
-
- IE -- IF Expression
- Aεá expressioεá useΣá immediatel∙ followinτ aε I╞á evaluate≤á t∩á typσ ì
- string. Only type numeric is permitted.
-
- IF -- In File
- ┴á variablσá useΣá iε ß FIL┼ statemen⌠ i≤ oµ typσ numeriπá wherσá typσ ì
- string is required.
-
- IP -- Input Prompt
- An input prompt string is not surrounded by quotes.
-
-
- IS -- Invalid Subscript
- A subscripted variable was referenced before it was dimensioned.
-
- IT -- Invalid Toggle
- An invalid compiler directive was encountered.
-
- IU -- Invalid Use
- A variable defined as an array is used with no subscripts.
-
- MF -- Mixed Format
- An expression evaluates to type string when type numeric is required.
-
- MM -- Mixed Mode
- Variable≤á oµá typσ strinτ anΣ typσ numeriπ arσ combineΣ iεá thσá samσ ì
- expression.
-
- MS -- Mixed String
- A numeric expression was used where a string expression is required.
-
- ND -- No DEFFN
- A FEND statement was encountered without a corresponding DEF.
-
- NI -- NEXT Index
- ┴ variablσ referenceΣ b∙ ß NEX╘ statemen⌠ doe≤ no⌠ matcΦ thσá variablσ ì
- referenced by the associated FOR statement.
-
- NU -- NEXT Unexpected
- A NEXT statement occurs without an associated FOR statement.
-
- OF -- Out of Function
- ┴ brancΦ ou⌠ oµ ß multiplσ linσ functioε froφ insidσ thσ functioεá wa≤ ì
- attempted.
-
- OO -- ON Overflow
- More than 25 ON statements were used in the program.
-
-
- PM -- ??
- ┴á DE╞ statemen⌠ appeareΣ withiε ß multiplσ linσ function«á Function≤ ì
- may not be nested.
-
- SE -- Syntax Error
- The source line contains a syntax error.
-
- SF -- SAVEMEM File
- ┴ SAVEME═ statemen⌠ use≤ aε expressioε oµ typσ numeriπ t∩ specif∙á thσ ì
- filσá t∩á bσá loaded«á Thi≤ expressioε mus⌠ bσá ßá string«á Possibl∙á thσ ì
- quotation marks were left off a string constant.
-
- SN -- Subscript Number
- A subscripted variable contains an incorrect number of subscripts.
-
- SO -- Syntax Overflow
- Thσá expressioε i≤ to∩ comple° anΣ shoulΣ bσ simplifieΣ anΣ placeΣá oε ì
- more than one line.
-
- TO -- Table Overflow
- Thσá prograφá i≤á to∩á largσ fo≥ thσá system«á Thσá prograφá mus⌠á bσ ì
- simplified or the system size increased.
-
- UL -- Undefined Line number
- A line number that does not exist has been referenced.
-
- US -- Undefined String
- A string has been terminated by a carriage return rather than quotes.
-
- VO -- Variable Overflow
- Variable names are too long for one statement.
- This should not occur.
-
- WE -- WHILE Error
- The expression immediately following a WHILE statement is not numeric.
-
- WU -- WHILE Undefined
- A WEND statement occurs without an associated WHILE statement.
- :CBASIC: Run-Time Error Messages -- Warnings
-
- Tw∩ textua∞ run-timσ erro≥ message≤ arσ presenteΣ b∙ CRUN:
-
- NO INTERMEDIATE FILE
- ┴á filσ namσ wa≤ no⌠ specifieΣ witΦ thσ CRU╬ command¼á o≥ n∩á filσá oµ ì
- typσ .IN╘ anΣ thσ specifieΣ filσ namσ wa≤ founΣ oε disk.
-
- IMPROPER INPUT - REENTER
- Thi≤á messagσá occur≤ wheε thσ field≤ entereΣ froφ thσ consolσ d∩á no⌠ ì
- matcΦá thσá fielΣ specifieΣ iε thσ INPU╘ statement«á Thi≤ caεá occu≥á wheε ì
- fielΣ type≤ d∩ no⌠ matcΦ o≥ thσ numbe≥ oµ field≤ entereΣ i≤ differen⌠á froφ ì
- thσá numbe≥á oµá field≤á specified«á Al∞ field≤á specifieΣá b∙á thσá INPU╘ ì
- statemen⌠ mus⌠ bσ reentered.
-
- 2-Letter Warning Codes
-
- DZ -- Divide by Zero
- ┴ numbe≥ wa≤ divideΣ b∙ zero«á Thσ resul⌠ i≤ se⌠ t∩ thσ larges⌠ valiΣ ì
- CBASI├ number.
-
- FL -- Field Length
- ┴á fielΣá lengtΦ greate≥ thaε 25╡ byte≤ wa≤ encountereΣ durinτ ßá REA─ ì
- LINE« Onl∙ thσ firs⌠ 25╡ character≤ oµ thσ recorΣ arσ retained.
-
- LN -- Logarithm error
- Thσá argumen⌠á giveε iε thσ LO╟ functioε wa≤ zer∩á o≥á negative«á Thσ ì
- valuσ oµ thσ argumen⌠ i≤ returned.
-
- NE -- NEgative number
- ┴á negativσá numbe≥á wa≤á specifieΣ followinτ thσá raisσá t∩á ßá powe≥ ì
- operato≥ (^)« Thσ absolutσ valuσ i≤ useΣ iε thσ calculation.
-
-
- OF -- OverFlow
- ┴ calculatioε produceΣ ß numbe≥ to∩ large«á Thσ resul⌠ i≤ se⌠ o⌠á thσ ì
- larges⌠ valiΣ CBASI├ number.
-
- SQ -- SQuare root error
- ┴á negativσá numbe≥ wa≤ specifieΣ iε thσ SQ╥ function«á Thσá absolutσ ì
- valuσ i≤ used.
- :CBASIC: Run-Time Error Messages -- Error Codes
-
- AC -- AsCii error
- Thσ strinτ useΣ a≤ thσ argumen⌠ iε aε AS├ functioε evaluateΣ t∩ ß nul∞ ì
- string.
-
- BN -- BUFF Number
- Thσá valuσ followinτ thσ BUF╞ optioε iε aε OPE╬ o≥ CREAT┼ statemen⌠ i≤ ì
- less than 1 or greater than 52.
-
- CC -- Chain Code
- ┴á chaineΣ program'≤ codσ areß i≤ large≥ thaε thσ maiε program'≤á codσ ì
- area.
-
- CD -- Chain Data
- ┴á chaineΣ program'≤ datß areß i≤ large≥ thaε thσ maiε program'≤á datß ì
- area.
-
- CE -- Close Error
- An error occurred upon closing a file.
-
- CF -- Chain Function
- ┴á chaineΣ program'≤ constan⌠ areß i≤ large≥ thaε thσá maiεá program'≤ ì
- constant area.
-
- CP -- Chain Var Storage
- ┴á chaineΣá program'≤á variablσ storagσ areß i≤ large≥ thaεá thσá maiε ì
- program's variable storage area.
-
- CS -- Chain SAVEMEM
- ┴ chaineΣ progrß reserveΣ ß differencσ amoun⌠ oµ memor∙ witΦ ß SAVEME═ ì
- statement than the main program.
-
- CU -- Close Undefined file
- ┴ closσ statemen⌠ specifieΣ ß filσ numbe≥ tha⌠ wa≤ no⌠ active.
-
- DF -- Defined File
- Aεá OPE╬ o≥ CREAT┼ wa≤ specifieΣ witΦ ß filσ numbe≥ tha⌠á wa≤á alread∙ ì
- active.
-
- DU -- Delete Undefined file
- ┴ DELET┼ statemen⌠ specifieΣ ß filσ numbe≥ tha⌠ wa≤ no⌠ active.
-
- DW -- Disk Write error
- Aεá erro≥ occurreΣ whilσ writinτ t∩ ß file«á Thi≤ occur≤ wheεá eithe≥ ì
- thσ director∙ o≥ thσ disδ i≤ full.
-
- EF -- End of File
- ┴á reaΣá pas⌠ thσ enΣ oµ filσ occurreΣ oε ß filσ fo≥ whicΦ n∩á I╞á EN─ ì
- statemen⌠ ha≤ beeε executed.
-
- ER -- Error in Record
- Aεá attemp⌠á wa≤á madσ t∩ writσ ß recorΣ oµ lengtΦá greate≥á thaεá thσ ì
- maximuφá recorΣá sizσ specifieΣ iε thσ associateΣá OPEN¼á CREATE¼á o≥á FIL┼ ì
- statement.
-
- FR -- File Rename
- Aε attemp⌠ wa≤ madσ t∩ renamσ ß filσ t∩ aε existinτ filσ name.
-
- FT -- File Toggle
- A FILE statement was executed when 20 files were already active.
-
- FU -- File Undefined
- Aε attemp⌠ wa≤ madσ t∩ reaΣ o≥ writσ t∩ ß filσ tha⌠ wa≤ no⌠ active.
-
- IF -- Invalid File name
- A file name was invalid.
-
- IR -- Invalid Record number
- A record number less than one was specified.
-
- IV -- Invalid Version
- Aεá attemp⌠á wa≤ madσ t∩ executσ aε IN╘ filσ createΣ b∙á ßá Versioεá ▒ ì
- Compiler.
-
- IX -- ??
- ┴áá FEN─á statemen⌠á wa≤á encountereΣá prio≥á t∩á executinτá ßá RETUR╬ ì
- statement.
-
- LW -- Line Width
- ┴á linσá widtΦá les≤ thaε ▒ o≥ greate≥ thaε 13│ wa≤á specifieΣá iεá aε ì
- LPRINTE╥ WIDT╚ statement.
-
- ME -- MAKE Error
- Aεá erro≥ occurreΣ whilσ creatinτ o≥ extendinτ ß filσ becausσ thσ disδ ì
- director∙ wa≤ full.
-
- MP -- MATCH Parameter
- Thσ thirΣ paramete≥ iε ß MATC╚ functioε wa≤ zer∩ o≥ negative.
-
- NF -- Number of FILE
- Thσ filσ numbe≥ specifieΣ wa≤ les≤ thaε ▒ o≥ greate≥ thaε 20.
-
- NM -- No Memory
- There was insufficient memory to load the program.
-
- NN -- No Number field
- Aε attemp⌠ wa≤ madσ t∩ prin⌠ ß numbe≥ witΦ ß PRIN╘ USIN╟ statemen⌠ bu⌠ ì
- therσ wa≤ no⌠ ß numeriπ datß fielΣ iε thσ USIN╟ string.
-
- NS -- No String field
- Aε attemp⌠ wa≤ madσ t∩ prin⌠ ß strinτ witΦ ß PRIN╘ USIN╟ statemen⌠ bu⌠ ì
- therσ wa≤ no⌠ ß strinτ fielΣ iε thσ USIN╟ string.
-
- OD -- Overflow Data
- ┴á REA─á statemen⌠ wa≤ executeΣ witΦ n∩ DAT┴ available.
-
- OE -- OPEN Error
- Aε attemp⌠ wa≤ madσ t∩ OPE╬ ß filσ tha⌠ didn'⌠ exis⌠ anΣ fo≥ whicΦá n∩ ì
- I╞ EN─ statemen⌠ haΣ beeε previousl∙ executed.
-
- OI -- ON Index
- Thσá expressioεá specifieΣá iεá aε O╬ ..«á GOSU┬ o≥á aεá O╬á ..«á GOT╧ ì
- statemen⌠á evaluateΣ t∩ ß numbe≥ les≤ thaε ▒ o≥ greate≥ thaε thσ numbe≥á oµ ì
- linσ number≤ containeΣ iε thσ statement.
-
- OM -- Overflow Memory
- The program ran out of memory during execution.
-
- QE -- Quote Error
- Aε attemp⌠ wa≤ madσ t∩ PRIN╘ t∩ ß filσ ß strinτ containinτ ß quotatioε ì
- mark.
-
- RB -- Random BUFF
- Randoφá acces≤ wa≤ attempteΣ t∩ ß filσ activateΣ witΦ thσ BUF╞á optioε ì
- specifying more than 1 buffer.
-
- RE -- READ Error
- Aε attemp⌠ wa≤ madσ t∩ reaΣ pas⌠ thσ enΣ oµ ß recorΣ iε ß fixeΣ file.
-
- RG -- RETURN with no GOSUB
- A RETURN occurred for which there was no GOSUB.
-
- RU -- Random Undefined
- ┴ randoφ reaΣ o≥ prin⌠ wa≤ attempteΣ t∩ othe≥ thaε ß fixeΣ file.
-
- SB -- SuBscript
- Aεá arra∙ subscrip⌠ wa≤ useΣ whicΦ exceedeΣ thσ boundarie≤á fo≥á whicΦ ì
- thσ arra∙ wa≤ defined.
-
- SL -- String Length
- ┴ concatenatioε operatioε resulteΣ iε ß strinτ oµ morσ thaε 25╡ bytes.
-
- SO -- SAVEMEM
- Thσ filσ specifieΣ iε ß SAVEME═ statemen⌠ coulΣ no⌠ bσ locateΣ oεá thσ ì
- referenced disk.
-
- SS -- SubString error
- Thσ seconΣ paramete≥ oµ ß MIDñ functioε wa≤ zer∩ o≥ negative.
-
- TF -- Too many Files
- Aε attemp⌠ wa≤ madσ t∩ havσ morσ thaε 2░ activσ file≤ simultaneously.
-
- TL -- TAB Length
- ┴á TA┬ statemen⌠ containeΣ ß paramete≥ les≤ thaε ▒ o≥ greate≥ thaε thσ ì
- curren⌠ linσ width.
-
- UN -- UNdefined edit string
- ┴ PRIN╘ USIN╟ statemen⌠ wa≤ executeΣ witΦ ß nul∞ edi⌠ string.
-
- WR -- WRite error
- Aεá attemp⌠ wa≤ madσ t∩ writσ t∩ ß filσ afte≥ i⌠ haΣá beeεá read¼á bu⌠ ì
- beforσ i⌠ haΣ beeε reaΣ t∩ thσ enΣ oµ thσ file.
- :CBASIC: CBASIC Reserved Words
-
- ABS AND AS ASC ATN
- BUFF CALL CHAIN CHR$ CLOSE
- COMMAND$ COMMON CONCHAR% CONSOLE CONSTAT%
- COS CREATE DATA DEF DELETE
- DIM ELSE END EQ EXP
- FEND FILE FOR FRE GE
- GO GOSUB GOTO GT IF
- INITIALIZE INP INPUT INT INT%
- LE LEFT$ LEN LET LINE
- LOG LPRINTER LT MATCH MID$
- NE NEXT NOT ON OPEN
- OR OUT PEEK POKE POS
- PRINT RANDOMIZE READ RECL RECS
- REM REMARK RENAME RESTORE RETURN
- RIGHT$ RND SADD SGN SIN
- SIZE SQR STEP STOP STR$
- SUB TAB TAN THEN TO
- UCASE$ USING VAL WEND WHILE
- WIDTH XOR
- :CBASIC2: Expression Hierarchy
-
- The Hierarchy for expression evaluation is a follows --
-
- 1. nested parentheses ()
- 2. power operator ^
- 3. * /
- 4. + - concatenation[+] unary[+ -]
- 5. relational operators:
- < <= > >= = <> LT LE GT GE EQ NE
- 6. NOT
- 7. AND
- 8. OR XOR
- :CBASIC2: Predefined Functions
-
- I/O Functions
-
- CONSTATÑ - Return≤ thσ consolσ statu≤ a≤ aε integer«á Iµ ready¼ ß logica∞ ì
- TRUE is returned.
- èCONCHAR% - Reads one character from the console device.
-
-
-
- Machine-Language Functions
-
- PEEK (<exp>)
- - Return≤á thσá content≤á oµá thσ memor∙ locatioεá giveεá b∙á thσ ì
- expression.
-
- POKE <exp>, <exp>
- - Low-orde≥ eigh⌠ bit≤ oµ seconΣ expressioε arσ storeΣ iεá memor∙ ì
- location selected by first expression.
-
- CALL <exp>
- - CALL a machine language program at address specified.
-
- SAVEMEM <constant>, <exp>
- - Reservσá <constant╛ numbe≥ oµ byte≤ anΣ loaΣ thσ filσ specifieΣ ì
- by the string <exp> into the reserved area.
-
- Numeric Functions
-
- FRE ABS(x) INT(x) INT%(x)
- FLOAT(i%) RND SGN(x) ATN(x)
- COS(x) EXP(x) LOG(x) [e] SIN(x)
- SQR(x) TAN(x)
-
- String Functions
-
- ASC(a$) CHR$(i%) LEFT$(a$,i%) LEN(a$)
- UCASE$(a$) MATCH(a$,b$,i%) MID$(a$,i%,j%) RIGHT$(a$,i%)
- STR$(x) VAL(a$) COMMAND$ SADD(a$)
-
-
- Disk Functions
-
- RENAME(a$,b$) SIZE(a$)
-
-
- User-Defined Functions
-
- The general forms are --
-
- [<line number>] DEF <function name> [<dummy arg list>] = <expression>
-
- and
-
- [<line number>] DEF <function name> [<dummy arg list>]
- .
- .
- .
- [<line number>] FEND