qdosmsq:vectors:inipr

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

qdosmsq:vectors:inipr [2009/02/09 17:37]
george.gwilt DC.W
qdosmsq:vectors:inipr [2009/02/10 10:05] (current)
george.gwilt
Line 1: Line 1:
 +====== BP_INIT/​SB_INIPR - Vector $110 ======
 +This vector initialises procedures and functions into the Basic name table and the Basic name list.
 +
 +^Call Parameters^^Return Parameters^^
 +|D3.L| Not used |D3.L|Corrupted. ​
 +|A1.L| Pointer to definition list |A1.L|Corrupted.|
 +|A6.L| The usual Basic pointer |A6.L|May be updated|
 +
 +===== Errors =====
 +No errors are returned by this vector call.
 +
 +
 +
 +===== Notes =====
 +  * All registers not shown above are not used on entry and are preserved on exit.
 +  * The Definition List has the form shown below at //defs//.
 +  * The number of procedures and the number of functions must be calculated as (the number of items + the total number of bytes in the names + 7)/8 with a minimum of the number of items. The reason for this is that this number is used to add space to both the name list and the name table. Whereas the name table entries are all exactly 8 bytes the additional length needed for the name list is the number of items (the number of bytes containing the length of the following name) plus the total number of bytes in all the additional names.
 +==== Definition List ====
 +
 +
 +<​code>​
 +defs   ​dc.w ​       procnum ​     ; Number of procedures (roughly)
 +; Then for each procedure
 +       ​dc.w ​       proutine-* ​  ; Relative pointer to routine  ​
 +       ​dc.b ​       proclen ​     ; Length of procedure name
 +       ​dc.b ​       procname ​    ; Procedure name
 +; Followed by:
 +       ​dc.w ​       0            ; Signals end of procedures
 +
 +
 +       ​dc.w ​       funcnum ​     ; Number of functions (roughly)
 +; Then for each function ​        
 +       ​dc.w ​       froutine-* ​  ; Relative pointer to routine
 +       ​dc.b ​       funclen ​     ; Length of function name
 +       ​dc.b ​       funcname ​    ; Function name
 +; Followed by:
 +       ​dc.w ​       0            ; Signals end of functions ​       ​
 +</​code> ​   ​
 + 
 +
 +===== Example =====
 +The example below shows the use of this trap .
 +
 +<​code>​
 +       ​lea ​        ​defs ​         ; Definition List
 +       ​movea.w ​    ​BP_INIT,​a1
 +       ​jmp ​        ​(a1) ​         ; Add new keywords and return to BASIC
 +</​code>​
 +
  
  • qdosmsq/vectors/inipr.txt
  • Last modified: 2009/02/10 10:05
  • by george.gwilt