CNA-BUG-057: RegisterAllBuiltInXnbReaders() documentation still calls the general EffectReader a known-unsupported placeholder
Evidence basis: source-verified at the pinned commit; tests exist (not executed for this page). Claims on this page were checked by reading the CNA source at commit 009d40f5; unless a sentence says otherwise, nothing here was built or executed. Nothing on this page was executed unless the Evidence section says so.
XnbBuiltInReaders.hpp says the function registers "the known-unsupported placeholder (the general EffectReader, XNB-32A)", but it registers the implemented EffectReader and the placeholder hook registers nothing.
- Identifier
CNA-BUG-057- Category
- Bug
- Subsystem
- Documentation & release tooling
- Status
- Open
- Verified against
- CNA
009d40f5(009d40f5dd085c4e674d3479675fac84b12b3e0a) - Severity
- Low (a triage suggestion, not a project priority)
- Evidence basis
- Source-verified: read at TARGET, not executed
- Tests touching this area
- Yes: see Current tests
- Affected contract
- CNA::Internal::Xnb::RegisterAllBuiltInXnbReaders() (doc comment in XnbBuiltInReaders.hpp)
Expected behaviour
The one call a game makes to register the built-in XNB readers documents what it registers: the implemented EffectReader (EffectContentTypeReader.cpp), which reads the bytecode length and bytes, constructs Graphics::Effect(device, bytes) and wraps failures in ContentLoadException; it is renderer-qualified, not a refusal. It does not imply .fx source, DXBC or MGFX support.
Actual behaviour at TARGET
The doc comment in XnbBuiltInReaders.hpp still lists "the known-unsupported placeholder (the general EffectReader, XNB-32A)". XnbBuiltInReaders.cpp calls RegisterEffectXnbReader(), and RegisterKnownUnsupportedXnbReaders() (KnownUnsupportedContentTypeReader.cpp) has an empty body whose comment says no built-in reader is in that category any more. The KnownUnsupportedContentTypeReader documentation was corrected; this comment was not, and it has been unchanged since the alpha.1 tag.
Source locations
modules/content/include/CNA/Internal/Xnb/XnbBuiltInReaders.hpp— RegisterAllBuiltInXnbReaders doc commentmodules/content/src/Xnb/XnbBuiltInReaders.cpp— RegisterAllBuiltInXnbReaders - registers the real EffectReadermodules/content/src/Xnb/EffectContentTypeReader.cpp— EffectReader::Readmodules/content/src/Xna/KnownUnsupportedContentTypeReader.cpp— RegisterKnownUnsupportedXnbReaders - empty
Evidence
Checked by reading at 009d40f5; not executed. Git history shows the comment identical at the alpha.1 tag and at 009d40f5, so an earlier conclusion that this was fixed (based on the implementation, registration and tests agreeing) missed this surviving comment. The site's XNB guide already describes the reader correctly ("EffectReader is renderer-qualified").
Focused reproduction
No focused reproduction is known. Nothing has been invented here; the evidence above is what exists.
Current tests
XnbBuiltInReaderRegistrationTests.cpp asserts that Microsoft.Xna.Framework.Content.EffectReader is registered; no test can check a doc comment.
Regression test
None beyond the existing registration test: the fix is a comment edit.
Blast radius
Readers of the header, typically someone porting a game who has to decide whether compiled Effect .xnb assets can load. No run-time behaviour is affected.
Workaround
No workaround is known.
Related pages
The same subject is explained at several altitudes. These are the neighbouring pages at each one.
- Internals
- Content runtime: registries
- Known issues
- Bug index