#REQUIRED, #IMPLIED, and Real Defaults

This is called the default declaration, but it doesn't always declare defaults. #REQUIRED and #IMPLIED are escape-hatches, the first saying that defaults are irrelevant because the attribute has to be there, the second that defaults are irrelevant because if the attribute isn't there, it just isn't there. Note that #REQUIRED only applies in valid documents (a missing #REQUIRED attribute is a validity error), but #IMPLIED often applies, because even a non-validating processor is required to do attribute defaulting for any declarations it actually reads.

If the default declaration is #REQUIRED or #IMPLIED, there is no default; this may sound obvious, but people have gotten confused on the basis that because there's a default declaration, then #REQUIRED must in some sense be a "default."

Back-link to spec

Copyright © 1998, Tim Bray. All rights reserved.