| 339 | */ |
| 340 | |
| 341 | static LIST * * var_enter( struct module_t * module, OBJECT * symbol ) |
| 342 | { |
| 343 | int found; |
| 344 | VARIABLE * v; |
| 345 | int n; |
| 346 | |
| 347 | if ( ( n = module_get_fixed_var( module, symbol ) ) != -1 ) |
| 348 | return &module->fixed_variables[ n ]; |
| 349 | |
| 350 | if ( !module->variables ) |
| 351 | module->variables = hashinit( sizeof( VARIABLE ), "variables" ); |
| 352 | |
| 353 | v = (VARIABLE *)hash_insert( module->variables, symbol, &found ); |
| 354 | if ( !found ) |
| 355 | { |
| 356 | v->symbol = object_copy( symbol ); |
| 357 | v->value = L0; |
| 358 | } |
| 359 | |
| 360 | return &v->value; |
| 361 | } |
| 362 | |
| 363 | |
| 364 | /* |
no test coverage detected