mirror of
https://gitlab.kitware.com/cmake/cmake.git
synced 2026-09-25 04:09:36 +03:00
cmCxxModuleMetadata: Don't serialize default values
Serializing defaults inside each preprocessor define inflats manifest size and makes auditing them more difficult. When "value" is empty or "undef" is false, don't serialize them at all.
This commit is contained in:
@@ -300,10 +300,10 @@ Json::Value SerializePreprocessorDefine(
|
||||
dv["name"] = d.Name;
|
||||
if (d.Value) {
|
||||
dv["value"] = *d.Value;
|
||||
} else {
|
||||
dv["value"] = Json::Value::null;
|
||||
}
|
||||
dv["undef"] = d.Undef;
|
||||
if (d.Undef) {
|
||||
dv["undef"] = d.Undef;
|
||||
}
|
||||
return dv;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user