P-Code Instructions (pcode.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
Ldf<t><n>
                                              Up Contents Index Back
──P-Code Instructions───────────────────────────────────────────────────────
 
  Syntax
 
  Ldf<t><n>
 
  /* Load frame relative item */
 
  Possible Instructions
 
  LdfBb, LdfBw, LdfDw, LdfRw, LdfTw, LdfW0...LdfW16, LdfWb, LdfWw, LdfLb,
  LdfLw
 
  See: P-Code Data Types
       P-Code Operands
 
  Description
 
  Loads the value of the specified local variable or function parameter
  onto the stack. A negative value for <n> addresses a local variable, and
  a positive value addresses a function parameter.
 
  NOTE: When Ldf<t>b is generated, the byte parameter is assumed to be a
        negative value. Thus, it refers only to local variables.
 
  // when <n> is a implied number #
 
  Push<t>(bp - fs - (2 *  #));
 
  // when <n> is a byte <b>
 
  Push<t>(bp + (2 * (<b> | 0xff00)));
 
  // when <n> is a word w
 
  Push<t>(bp + (2 * w));
 
 
                                     -♦-