home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The C Users' Group Library 1994 August
/
wc-cdrom-cusersgrouplibrary-1994-08.iso
/
listings
/
v_02_09
/
2n09028a
< prev
next >
Wrap
Text File
|
1991-05-06
|
776b
|
38 lines
; TEENY.ASM
; Tiniest C Startup code for Turbo C 2.0 or
; Turbo C++ 1.0 Tiny Model
; define the standard Turbo C segments
; in their correct order
_TEXT SEGMENT BYTE PUBLIC 'CODE'
EXTRN _main:near
_TEXT ENDS
_DATA SEGMENT WORD PUBLIC 'DATA'
_DATA ENDS
_BSS SEGMENT WORD PUBLIC 'BSS'
_BSS ENDS
; Add a "HEAP" segment so that we can cheat and dynamically
; allocate memory even though we have a COM file format.
_BSSHEAP SEGMENT PARA PUBLIC 'HEAP'
public __ENDDATA
__ENDDATA label byte ;hook for dynamic memory allocation
_BSSHEAP ENDS
DGROUP GROUP _TEXT, _DATA, _BSS, _BSSHEAP
DGROUP GROUP _TEXT, _DATA, _BSS
_TEXT SEGMENT
ORG 100H
assume cs:_TEXT
BEGIN:
jmp _main
_TEXT ENDS
END BEGIN