home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 9 / 09.iso / l / l042 / 1.ddi / CHAP5.ARC / INTEGRAT.ASM < prev    next >
Encoding:
Assembly Source File  |  1987-12-30  |  839 b   |  32 lines

  1. ;
  2. ; The following file contains glue code for calling
  3. ; routines defined outside of the "Integrat" unit.
  4. ;
  5. DATA      SEGMENT  PUBLIC
  6. DATA      ENDS
  7.  
  8. CODE      SEGMENT  PUBLIC
  9.  
  10.           ASSUME   CS:CODE, DS:DATA
  11.  
  12.           PUBLIC   UserFunction        ;Make routines known
  13.  
  14. ;function UserFunction(X : real; ProcAddr : Pointer) : real;
  15.  
  16. UserFunction   PROC FAR
  17.  
  18.                POP      AX             ;Get return address
  19.                POP      BX
  20.                POP      CX             ;Proc offset
  21.                POP      DX             ;Proc segment
  22.                PUSH     BX             ;Push return address
  23.                PUSH     AX
  24.                PUSH     DX
  25.                PUSH     CX
  26.                RET                     ;Jump to proc
  27.  
  28. UserFunction   ENDP
  29.  
  30. CODE           ENDS
  31.                END
  32.