public static symbol make_symbol( byte[] name ) { lock( table ) { int hash_number = foreign.get_hash_power_number( name, 12 ); bucket _bucket = table[hash_number]; if (_bucket == null) { symbol _symbol = new symbol( nil._nil, name ); table[hash_number] = new bucket( _symbol, null ); return _symbol; } for (bucket run = _bucket ; (run != null) ; run = run.next) if (foreign.bigloo_strcmp( run.symb.pname, name )) return run.symb; symbol result = new symbol( nil._nil, name ); table[hash_number] = new bucket( result, _bucket ); return result; } }
public static byte[] SYMBOL_TO_STRING( symbol o ) { // CARE why not a correct signature in Scheme return o.pname; }
public static Object SET_SYMBOL_PLIST( symbol o, Object v ) { o.cval= v; return unspecified._unspecified; }
public static bstruct make_struct( symbol key, int size, Object o ) { return new bstruct( key, size, o ); }
public static Object GET_SYMBOL_PLIST( symbol o ) { return o.cval; }
public static bstruct create_struct( symbol key, int size ) { return new bstruct( key, size ); }
public static int bgl_symbol_hash_number( symbol obj ) { return (1 + bgl_string_hash_number( SYMBOL_TO_STRING( obj ) )); }
public bucket( symbol symb, bucket next ) { this.symb = symb; this.next = next; }