QDoc: Route ContentBuilder diagnostics through Location
ContentBuilder lives in QDocLib and can't depend on QDoc's Location
class for diagnostic output. When it encounters malformed atom
chains, warnings go to stderr with no source file information,
making them difficult to trace back to the offending documentation.
ContentBuilder now accepts an optional diagnostic callback that
callers provide. NodeExtractor binds each callback to the doc
comment's Location, so warnings include the file and line where
the problem originates. The IR layer remains dependency-free while
gaining source-located diagnostics.
Task-number: QTBUG-143355
Change-Id: I52491ae137ecabef6420a722e6b79f7e683e58ea
Reviewed-by: Topi Reinio <topi.reinio@qt.io>