qc.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.
_segment
 Example                                   Up Contents Index Back
────────────────────────────────────────────────────────────────────────────
 
  Keyword:   _segment
 
  Syntax:    _segment declarator
 
  Summary:   Data type used to store a segment address.
 
  See also:  _based, _bfreeseg, _bheapseg, _bmalloc, _segname, _self
 
     The _segment data type is used to declare a based variable.
 
     For example, in the following declarations, the variable chp is a
     pointer:
 
          char *chp;
          int i;
 
          // Based on a pointer's segment
          char _based( (_segment)chp )*b_p;
 
          // Based on an address's segment
          double _based( (_segment)&i )*b_a;
 
     As an address, chp is cast to the type _segment, which becomes the
     base for b_p. Similarly, i is an integer whose address can be cast
     to a segment and used as a base for b_a.
                                    -♦-