mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-30 09:58:55 +08:00
refactor: bcs split class structure
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
2aabe27531
commit
0597f064e5
@@ -102,6 +102,7 @@ struct DebugVarBase {
|
||||
this->set(data);
|
||||
}
|
||||
}
|
||||
|
||||
void setPrefixType(DebugVarPrefix data) {
|
||||
prefixType = std::move(data);
|
||||
}
|
||||
@@ -117,6 +118,13 @@ struct DebugVarBase {
|
||||
return (value != defaultValue) ? static_cast<UserType>(value) : userValue;
|
||||
}
|
||||
|
||||
template <typename UserType>
|
||||
void assignIfNotDefault(UserType &userDataForAssignment) const {
|
||||
if (value != defaultValue) {
|
||||
userDataForAssignment = static_cast<UserType>(value);
|
||||
}
|
||||
}
|
||||
|
||||
private:
|
||||
T value;
|
||||
T defaultValue;
|
||||
|
||||
Reference in New Issue
Block a user