| 1410 | DAS_THREAD_LOCAL(TStaticStorage) g_static_storage; |
| 1411 | |
| 1412 | void gc0_save_ptr ( char * name, void * data, Context * context, LineInfoArg * line ) { |
| 1413 | uint64_t hash = hash_function ( *context, name ); |
| 1414 | if ( g_static_storage->find(hash)!=g_static_storage->end() ) { |
| 1415 | context->throw_error_at(line, "gc0 already there %s (or hash collision)", name); |
| 1416 | } |
| 1417 | (*g_static_storage)[hash] = data; |
| 1418 | } |
| 1419 | |
| 1420 | void gc0_save_smart_ptr ( char * name, smart_ptr_raw<void> data, Context * context, LineInfoArg * line ) { |
| 1421 | gc0_save_ptr(name, data.get(), context, line); |
no test coverage detected