We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9020450 commit 7abc643Copy full SHA for 7abc643
nautilus-api/include/Interface/DataTypes/Val.hpp
@@ -171,9 +171,17 @@ namespace nautilus {
171
172
#else
173
174
- inline val<ValueType>(ValueType value) : value(value) {};
+ inline val<ValueType>(ValueType value) : value(value), state(tracing::traceConstant(value)) {
175
+ if (tracing::inTracer()) {
176
+ tracing::getVarRefMap()[state]++;
177
+ }
178
+ };
179
- inline val<ValueType>(const val<ValueType> &other) : value(other.value) {};
180
+ inline val<ValueType>(const val<ValueType> &other) : value(other.value), state(other.state) {
181
182
183
184
185
#endif
186
187
#ifdef ENABLE_TRACING
0 commit comments