Consider:
<xs:element name="spare" dfdl:length="{ $tns:WordPaddingBits }">
<xs:simpleType dfdl:lengthKind="explicit">
<xs:annotation>
<xs:appinfo source="http://www.ogf.org/dfdl/">
<dfdl:assert test="{ . eq 0 }" />
</xs:appinfo>
</xs:annotation>
<xs:restriction base="xs:unsignedInt">
<xs:enumeration value="0" />
</xs:restriction>
</xs:simpleType>
</xs:element>

Now, suppose the variable tns:WordPaddingBits has value 0. 
So this padding integer will be length 0 (this binary data with lengthUnits bits). 
Currently, Daffodil gives a runtime SDE on this. The assert test expression complains that "." has no value.
I would claim this should either provide a value of 0 for this integer, or it should be a parse error because you must have at least 1 bit.

Thoughts?
Mike Beckerle | OGF DFDL Workgroup Co-Chair | Owl Cyber Defense | www.owlcyberdefense.com (Tresys is now part of Owl)
Please note: Contributions to the DFDL Workgroup's email discussions are subject to the OGF Intellectual Property Policy