[mlir][irdl] Fix crash in TypeOp/AttributeOp verify on empty sym_name (#184598)
TypeOp::verify() and AttributeOp::verify() called StringRef::front() to
check for leading '\!' or '#' sigils before passing the name to
isValidName(). When sym_name is empty, front() triggers an assertion
failure:
Assertion `\!empty()' failed.
Fix: guard the front() calls with an emptiness check. An empty sym_name
then falls through to isValidName(), which already emits a proper
diagnostic:
error: name of type is empty
Fixes #159949