-
- Downloads
Enhance LLInstanceTracker variants to be more uniform.
For both the (so far unused) generic KEY form and the KEY = T* form, provide key_iter, beginKeys(), endKeys(). Change instance_iter so that when dereferenced, it gives you a T& rather than a T*, to be more harmonious with a typical STL container. (You parameterize LLInstanceTracker with T, not with T*.) Fix existing usage in llfasttimer.cpp and lltimer.cpp to agree. For the KEY = T* specialization, add T* getInstance(T*) so client isn't forced to know which variant was used. Add unit tests for uniformity of public operations on both variants.
Showing
- indra/llcommon/CMakeLists.txt 1 addition, 0 deletionsindra/llcommon/CMakeLists.txt
- indra/llcommon/llinstancetracker.h 64 additions, 26 deletionsindra/llcommon/llinstancetracker.h
- indra/llcommon/lltimer.cpp 6 additions, 6 deletionsindra/llcommon/lltimer.cpp
- indra/llcommon/tests/llinstancetracker_test.cpp 160 additions, 0 deletionsindra/llcommon/tests/llinstancetracker_test.cpp
Loading
Please register or sign in to comment