Translate inline assembly errors back to source locations

Fixes #17552.