@var() diagnostics: generate more dwarf detail & context
For TLS-related variables like @var("errno") in glibc, some
useful diagnostic details were just dropped on the floor as
semantic_error objects were caught but not printed. New code
tries to arrange for these to be chained instead of lost. In
exchange, more errors would propagate to session.print_error
as chained to the target_symbol, so now the code also has to
duplicate-eliminate the chained errors.
The net result is that at verbosity 0 or 1, we appear to get only a
few specific and valuable incremental messages, which point to the
problematic dwarf. It would be nice to simplify this stuff, perhaps
by storing context (script-source level data, dwarf pointers, dwarf
contents, etc.) as RAII style global stack of "current details".