Fix search for shadowed const declarations by a var declarations to search for any variable instead of only a blockScoped one to ensure we are not picking it up from a wrong scope.
Respond to code review comments
Allow const and let declarations to be exported in modules. Also ensure that const module elements are not used as references.
Treat blockScoped variable declarations as a separate category when it comes to symbol flags, instead of compining BlockScoped and Variable