Currently all static vars local to a function are issued in the main scope of the function. This change ensures that statics local to a lexical block are issued in the DWARF in the correct lexical block.
For example:
void foo()
{
static int local = 1234; { static int local = 5678; }
}
This change detects debug info meta data assigned to a lexical block and defers its issuing to DWARF until we are in the correct lexical block.
There is a matching change to clang to ensure the debug info meta-data is assigned to the lexical block.
A matching test is to be added to the debuginfo-tests repository.
Fix typos separately, rather than mixing them in with a functional change.