C++ feature checks: Match warnings more strictly
Require the word "warning" to appear at the start of a line, after
whitespace, or after a :
. This is the same that CTest launchers use
to match warnings. It avoids matching "warning" inside file paths.
Fixes: #19019 (closed)