I'm working on a SVDSuite, a Python package to parse, process, manipulate, validate, and generate CMSIS SVD files. During development, I noticed a discrepancy between documentation and schema.
According to the documentation, derivedFrom can be referenced from another scope for elements cluster, register, field, and enumeratedValues. However, in the schema, the type for the derivedFrom attribute is dimableIdentifierType which does not allow the . character. Furthermore, the enumeratedValue element in enumeratedValues must be specified (minOccurs set to 1), which doesn't make sense for deriving. This issue was already reported here.
This PR addresses the described issues. It contains the following changes:
add referenceIdentifierType (allows <dimableIdentifierType>.<dimableIdentifierType> with any depth, but not .<dimableIdentifierType>, .<dimableIdentifierType>., or <dimableIdentifierType>.)
change minOccurs for element enumeratedValue from 1 to 0 to allow deriving
change enumeratedValues derivedFrom attribute type to referenceIdentifierType to allow referencing
change field derivedFrom attribute type to referenceIdentifierType to allow referencing from another scope
change register derivedFrom attribute type to referenceIdentifierType to allow referencing from another scope
change cluster derivedFrom attribute type to referenceIdentifierType to allow referencing from another scope
modify svd_schema.txt so that the documentation corresponds to the schema
Please let me know what you think about the PR and if it needs any modifications.
I'm working on a SVDSuite, a Python package to parse, process, manipulate, validate, and generate CMSIS SVD files. During development, I noticed a discrepancy between documentation and schema.
According to the documentation,
derivedFrom
can be referenced from another scope for elementscluster
,register
,field
, andenumeratedValues
. However, in the schema, the type for thederivedFrom
attribute isdimableIdentifierType
which does not allow the.
character. Furthermore, theenumeratedValue
element inenumeratedValues
must be specified (minOccurs
set to 1), which doesn't make sense for deriving. This issue was already reported here.This PR addresses the described issues. It contains the following changes:
<dimableIdentifierType>.<dimableIdentifierType>
with any depth, but not.<dimableIdentifierType>
,.<dimableIdentifierType>.
, or<dimableIdentifierType>.
)Please let me know what you think about the PR and if it needs any modifications.