This vector allows a parameter to either a machine code procedure or function to be changed.
Call Parameters | Return Parameters | ||
---|---|---|---|
D0.L | Unused | D0.L | Error code. |
D1.L | Unused | D1.L | Corrupted. |
D2.L | Unused | D2.L | Corrupted. |
D3.L | Unused | D3.L | Corrupted. |
A0.L | Unused | A0.L | Corrupted. |
A1.L | Unused | A1.L | Corrupted. |
A2.L | Unused | A2.L | Corrupted. |
A3.L | Pointer to parameter | A3.L | Preserved. |
A6.L | SuperBASIC pointer | A6.L | May be changed. |
ERR_BP | Bad Parameter. |
The example below shows an integer parameter being halved.
move.w CA_GTINT,A2 ; CA_GTINT vector address. jsr (a2) ; Put the parameter on the maths stack. bne.s Error_handler ; Oops! asr (a1,a6.l) ; Halve the parameter. movea.w BP_LET,(a2) ; BP_LET vector address. jsr (a2) ; Put the new value from the maths stack. bne.s Error_handler ; Oops!