Changeset 538 for trunk/thune/urlan.c
- Timestamp:
- 06/14/08 16:30:57 (6 months ago)
- Files:
-
- 1 modified
-
trunk/thune/urlan.c (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/thune/urlan.c
r511 r538 308 308 FIXED_ATOM( "case", 4, UR_ATOM_CASE ) 309 309 FIXED_ATOM( "reader-macros", 13, UR_ATOM_READER_MACROS ) 310 FIXED_ATOM( "words", 5, UR_ATOM_WORDS ) 311 //FIXED_ATOM( "key-values", 10, UR_ATOM_KEY_VALUES ) 312 313 // ^^ Add new fixed atoms here ^^ 314 // Reduce ATOMS_RESERVED for each new FIXED_ATOM to keep the number of 315 // atoms constant. When it drops below zero then it should be reset to 316 // 10 and all library users who have their own fixed atoms must recompile. 317 318 #define ATOMS_RESERVED 10 319 { 320 static char resFixed[13] = "_res-fixed-0"; 321 int i; 322 for( i = 0; i < ATOMS_RESERVED; ++i ) 323 { 324 resFixed[11] = i + '0'; 325 ur_intern( resFixed, 12 ); 326 } 327 } 310 328 311 329 #if MAKE_ATOM_HEADER … … 826 844 UBlock* ur_blockPtrT( UThread* ut, UIndex n) 827 845 { 828 if( n < 0)846 if( isGlobalIndex(n) ) 829 847 return (((UBlock*) ut->env->blocks.arr.ptr.v) - n); 830 848 return (((UBlock*) ut->blocks.arr.ptr.v) + n); … … 834 852 UArray* ur_binPtrT( UThread* ut, UIndex n ) 835 853 { 836 if( n < 0)854 if( isGlobalIndex(n) ) 837 855 return (((UArray*) ut->env->bin.arr.ptr.v) - n); 838 856 return (((UArray*) ut->bin.arr.ptr.v) + n); … … 842 860 UResource* ur_resPtrT( UThread* ut, UIndex n ) 843 861 { 844 if( n < 0)862 if( isGlobalIndex(n) ) 845 863 return (((UResource*) ut->env->resources.arr.ptr.v) - n); 846 864 return (((UResource*) ut->resources.arr.ptr.v) + n);
