From 4dfb5456b0b9d050126879fcc48d8da9dc44942a Mon Sep 17 00:00:00 2001 From: Philippe Canal Date: Wed, 29 Nov 2023 14:45:16 -0600 Subject: [PATCH 1/3] Correct spelling of version tag in pragma read. It needs to be 'version' without a trailing s --- root/io/issue-7754/read_cmssw_class_v3.cxx | 8 ++++---- root/io/issue-9899/read_cmssw_class_v3.cxx | 4 ++-- root/io/issue-9899/write_cmssw_class_v2.cxx | 4 ++-- root/io/transient/execAtomTransient.cxx | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/root/io/issue-7754/read_cmssw_class_v3.cxx b/root/io/issue-7754/read_cmssw_class_v3.cxx index 2b33872d52..b11cc38d94 100644 --- a/root/io/issue-7754/read_cmssw_class_v3.cxx +++ b/root/io/issue-7754/read_cmssw_class_v3.cxx @@ -59,10 +59,10 @@ void Print(const Holder &h) } #ifdef __ROOTCLING__ -#pragma read sourceClass="SubContent" targetClass="SubContent" versions="[2]" source="int fValue" target="fValue" code="{ fValue = 100 * onfile.fValue; }" -#pragma read sourceClass="SubContent" targetClass="SubContent" versions="[2]" source="int fValue" target="fNewValue" code="{ fNewValue = 3000 * onfile.fValue; }" -#pragma read sourceClass="Content" targetClass="Content" versions="[2]" source="float fAfter" target="fAfter" code="{ fAfter = 10 * onfile.fAfter; }" -#pragma read sourceClass="Content" targetClass="Content" versions="[2]" source="float fAfter" target="fNewData" code="{ fNewData = 20 * onfile.fAfter; }" +#pragma read sourceClass="SubContent" targetClass="SubContent" version="[2]" source="int fValue" target="fValue" code="{ fValue = 100 * onfile.fValue; }" +#pragma read sourceClass="SubContent" targetClass="SubContent" version="[2]" source="int fValue" target="fNewValue" code="{ fNewValue = 3000 * onfile.fValue; }" +#pragma read sourceClass="Content" targetClass="Content" version="[2]" source="float fAfter" target="fAfter" code="{ fAfter = 10 * onfile.fAfter; }" +#pragma read sourceClass="Content" targetClass="Content" version="[2]" source="float fAfter" target="fNewData" code="{ fNewData = 20 * onfile.fAfter; }" #endif diff --git a/root/io/issue-9899/read_cmssw_class_v3.cxx b/root/io/issue-9899/read_cmssw_class_v3.cxx index 17bf630fdf..54f319aabb 100644 --- a/root/io/issue-9899/read_cmssw_class_v3.cxx +++ b/root/io/issue-9899/read_cmssw_class_v3.cxx @@ -43,9 +43,9 @@ struct Values { #ifdef __ROOTCLING__ #pragma read sourceClass="RefVectorBase" targetClass="RefVectorBase" source="" \ - versions="1-" target="fTransient" code="{ fTransient.clear(); }" + version="1-" target="fTransient" code="{ fTransient.clear(); }" #pragma read sourceClass="RefVectorMemberPointersHolder" targetClass="RefVectorMemberPointersHolder" source="" \ - versions="1-" target="fTransient" code="{ fTransient.clear(); }" + version="1-" target="fTransient" code="{ fTransient.clear(); }" #pragma read sourceClass="LowData" targetClass="LowData" source="Values fValues" \ checksum="[0x16066232]" target="fNewValues" code="{ fNewValues = onfile.fValues; }" #endif diff --git a/root/io/issue-9899/write_cmssw_class_v2.cxx b/root/io/issue-9899/write_cmssw_class_v2.cxx index 314f911e5a..809256d708 100644 --- a/root/io/issue-9899/write_cmssw_class_v2.cxx +++ b/root/io/issue-9899/write_cmssw_class_v2.cxx @@ -45,9 +45,9 @@ struct Values { #ifdef __ROOTCLING__ #pragma read sourceClass="RefVectorBase" targetClass="RefVectorBase" source="" \ - versions="1-" target="fTransient" code="{ fTransient.clear(); }" + version="1-" target="fTransient" code="{ fTransient.clear(); }" #pragma read sourceClass="RefVectorMemberPointersHolder" targetClass="RefVectorMemberPointersHolder" source="" \ - versions="1-" target="fTransient" code="{ fTransient.clear(); }" + version="1-" target="fTransient" code="{ fTransient.clear(); }" #endif struct LowData { diff --git a/root/io/transient/execAtomTransient.cxx b/root/io/transient/execAtomTransient.cxx index 6dac20566a..e01c538182 100644 --- a/root/io/transient/execAtomTransient.cxx +++ b/root/io/transient/execAtomTransient.cxx @@ -12,7 +12,7 @@ class Holder { #ifdef __ROOTCLING__ #pragma link C++ class Holder+; -#pragma read sourceClass="Holder" targetClass="Holder" versions="[1-]" source="" target="fCache" code="{ fCache = nullptr; }" +#pragma read sourceClass="Holder" targetClass="Holder" version="[1-]" source="" target="fCache" code="{ fCache = nullptr; }" #endif From c64da265d98159728fef34a8ac8f20d8e9de2689 Mon Sep 17 00:00:00 2001 From: Philippe Canal Date: Thu, 21 Dec 2023 11:46:32 -0600 Subject: [PATCH 2/3] Correct pragma read version syntax. Need to have a comma separated list of version specifiers or a version range (eg `4-`) enclosed in *square brackets*. --- root/io/issue-9899/read_cmssw_class_v3.cxx | 4 ++-- root/io/issue-9899/write_cmssw_class_v2.cxx | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/root/io/issue-9899/read_cmssw_class_v3.cxx b/root/io/issue-9899/read_cmssw_class_v3.cxx index 54f319aabb..438d969331 100644 --- a/root/io/issue-9899/read_cmssw_class_v3.cxx +++ b/root/io/issue-9899/read_cmssw_class_v3.cxx @@ -43,9 +43,9 @@ struct Values { #ifdef __ROOTCLING__ #pragma read sourceClass="RefVectorBase" targetClass="RefVectorBase" source="" \ - version="1-" target="fTransient" code="{ fTransient.clear(); }" + version="[1-]" target="fTransient" code="{ fTransient.clear(); }" #pragma read sourceClass="RefVectorMemberPointersHolder" targetClass="RefVectorMemberPointersHolder" source="" \ - version="1-" target="fTransient" code="{ fTransient.clear(); }" + version="[1-]" target="fTransient" code="{ fTransient.clear(); }" #pragma read sourceClass="LowData" targetClass="LowData" source="Values fValues" \ checksum="[0x16066232]" target="fNewValues" code="{ fNewValues = onfile.fValues; }" #endif diff --git a/root/io/issue-9899/write_cmssw_class_v2.cxx b/root/io/issue-9899/write_cmssw_class_v2.cxx index 809256d708..2efd95615f 100644 --- a/root/io/issue-9899/write_cmssw_class_v2.cxx +++ b/root/io/issue-9899/write_cmssw_class_v2.cxx @@ -45,9 +45,9 @@ struct Values { #ifdef __ROOTCLING__ #pragma read sourceClass="RefVectorBase" targetClass="RefVectorBase" source="" \ - version="1-" target="fTransient" code="{ fTransient.clear(); }" + version="[1-]" target="fTransient" code="{ fTransient.clear(); }" #pragma read sourceClass="RefVectorMemberPointersHolder" targetClass="RefVectorMemberPointersHolder" source="" \ - version="1-" target="fTransient" code="{ fTransient.clear(); }" + version="[1-]" target="fTransient" code="{ fTransient.clear(); }" #endif struct LowData { From 3381cda7fef9ac6d0457b3d0da93d7dcd4386484 Mon Sep 17 00:00:00 2001 From: Philippe Canal Date: Fri, 11 Apr 2025 12:54:51 -0500 Subject: [PATCH 3/3] Adjust to extra AutoParsing debug information --- .../autoloading/headerParsingOnDemand/headerParsingOnDemand.ref | 1 + 1 file changed, 1 insertion(+) diff --git a/root/meta/autoloading/headerParsingOnDemand/headerParsingOnDemand.ref b/root/meta/autoloading/headerParsingOnDemand/headerParsingOnDemand.ref index 24e87f4083..0ba34e19e4 100644 --- a/root/meta/autoloading/headerParsingOnDemand/headerParsingOnDemand.ref +++ b/root/meta/autoloading/headerParsingOnDemand/headerParsingOnDemand.ref @@ -3,6 +3,7 @@ Processing runFullheaderParsingOnDemand.C... Class name myClass0 Info in : loaded library libFullheaderParsingOnDemand_dictrflx.so for myClass0 Info in : Parsing full payload for myClass0 +Info in : Parsed 1 headers for myClass0 Class name myClass1 Class name myClass1 Class name myClass2