Changeset 4653 for trunk/tools/fastdep/avl.c
- Timestamp:
- Nov 21, 2000, 5:35:37 AM (25 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/tools/fastdep/avl.c
r3212 r4653 1 /* $Id: avl.c,v 1. 2 2000-03-24 01:40:52bird Exp $1 /* $Id: avl.c,v 1.3 2000-11-21 04:35:36 bird Exp $ 2 2 * 3 3 * AVL-Tree (lookalike) implementation. … … 18 18 #define AVL_HEIGHTOF(pNode) ((unsigned char)((pNode) != NULL ? pNode->uchHeight : 0)) 19 19 #define max(a,b) (((a) > (b)) ? (a) : (b)) 20 21 #ifndef INLINE 22 # if defined(__IBMC__) 23 # define INLINE _Inline 24 # elif defined(__IBMCPP__) 25 # define INLINE inline 26 # elif defined(__WATCOMC__) 27 # define INLINE __inline 28 # elif defined(__WATCOM_CPLUSPLUS__) 29 # define INLINE inline 30 # else 31 # error message("unknown compiler - inline keyword unknown!") 32 # endif 33 #endif 20 34 21 35 … … 32 46 #include "string.h" 33 47 48 #if defined(__IBMCPP__) || defined(__IBMC__) 34 49 #include <builtin.h> 35 #define assert(a) ((a) ? (void)0 : __interrupt(3)) 50 #define assert(a) ((a) ? (void)0 : __interrupt(3) ) 51 #else 52 #include <assert.h> 53 #endif 36 54 37 55 … … 58 76 * Internal Functions * 59 77 *******************************************************************************/ 60 _Inlinevoid AVLRebalance(PAVLSTACK pStack);78 INLINE void AVLRebalance(PAVLSTACK pStack); 61 79 62 80 … … 651 669 * @remark 652 670 */ 653 _Inlinevoid AVLRebalance(PAVLSTACK pStack)671 INLINE void AVLRebalance(PAVLSTACK pStack) 654 672 { 655 673 while (pStack->cEntries > 0)
Note:
See TracChangeset
for help on using the changeset viewer.