EasyManuals Logo
Home>Texas Instruments>Calculator>TI-89

Texas Instruments TI-89 Developer's Guide

Texas Instruments TI-89
1398 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #900 background imageLoading...
Page #900 background image
858
Appendix A: System Routines — Memory Management
TI
-
89 / TI
-
92 Plus Developer Guide
Not for Distribution
Beta Version January 26, 2001
HeapPtrToHandle
Declaration:
HANDLE
HeapPtrToHandle
(void const *
ptr
)
Category(ies):
Memory Management
Description:
Find the handle associated with a dereferenced pointer by searching the
table of handle pointers for the given pointer.
Inputs:
ptr
A dereferenced pointer to the heap.
Outputs:
HANDLE of dereferenced pointer or H_NULL if not found.
Assumptions:
The heap has not been compressed since the dereferenced pointer was
originally obtained or the block it points to is locked.
Side Effects:
This routine searches the entire handle table and so should be used
accordingly.
Availability:
All versions of the TI
-
89 / TI
-
92 Plus.
TI
-
89 / TI
-
92 Plus
Differences:
None
See Also:
None
Example:
HANDLE h1, h2;
void *Ptr;
if (h1 = HeapAlloc(1000)) {
Ptr = HLock( h1 ); /* Lock handle, return pointer to memory */
h2 = HeapPtrToHandle( Ptr ); /* h2 better be same as h1 */
if (h1 != h2)
DlgMessage("ERROR", "Pointers do not match", PDB_CANCEL, 0 );
HeapFree( h1 ); /* do not have to unlock it to free it */
}

Table of Contents

Other manuals for Texas Instruments TI-89

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Texas Instruments TI-89 and is the answer not in the manual?

Texas Instruments TI-89 Specifications

General IconGeneral
Display size (HxV)100 x 160 mm
Memory type639K FLASH ROM, 188K bytes RAM
Compatible operating systemsOperating System 2.09
Battery typeAAA

Related product manuals