×   Main Menu ALL The 8BS News Manuals (New menu) Links Worth a Look Tools Disc and Basic Webring Site Map 8BS Guestbook Old Guest Book Me The Barnsley Rovers   
8-Bit Software

The BBC and Master Computer Public Domain Library

AE11 LEN

Submitted by Steve Fewell

Description:

Call the Evaluate value routine (&AD36) which will evaluate the next value at BASIC text
pointer B location, or the expression at that location if the value begins with an open bracket ("(").
If the value obtained is not a String (A isn't 0) then issue a Type mismatch error, as the LENgth
can only be obtained for a string value.

Set A to the value in &36 (The SWA length).
Continue to routine &AE18 to set the IWA to the 8-bit value contained in A and exit.


Disassembly for the LEN routine

AE0E L 076 146 144 4C 92 90 JMP &9092 Type mismatch error
AE11 6 032 054 173 20 36 AD JSR &AD36 Evaluate value
AE14   208 248 D0 F8 BNE -8 --> &AE0E
AE16 6 165 054 A5 36 LDA &36
AE18   ...IWA = 8-bit value

 


 Back to 8BS
Or