 Collect mapping from import name to to list of symbols it exports.
importNamesWithTables :: [InScoped ImportDecl] -> [(ModuleName (), Table)]
importNamesWithTables = map (getImportModuleName &&& getImportedSymbols)
  where
    getImportedSymbols :: InScoped ImportDecl -> Table
    getImportedSymbols = fromImportInfo . pullScopedInfo

    fromImportInfo :: NameInfo l -> Table
    fromImportInfo (Import dict) = dict
    fromImportInfo _             = mempty

-- | Returns pair of line numbers — first and last line of import section
-- if any import is in list.
impor
importNamesWithTables :: [InScoped ImportDecl] -> [(ModuleName (), Table)]
importNamesWithTables = map (getImportModuleName &&& getImportedSymbols)
  where
    getImportedSymbols :: InScoped ImportDecl -> Table
    getImportedSymbols = fromImportInfo . pullScopedInfo

    fromImportInfo :: NameInfo l -> Table
    fromImportInfo (Import dict) = dict
    fromImportInfo _             = mempty

-- | Returns pair of line numbers — first and last line of import section
-- if any import is in list.
importNamesWithTables = map (getImportModuleName &&& getImportedSymbols)
  where
    getImportedSymbols :: InScoped ImportDecl -> Table
    getImportedSymbols = fromImportInfo . pullScopedInfo

    fromImportInfo :: NameInfo l -> Table
    fromImportInfo (Import dict) = dict
    fromImportInfo _             = mempty

-- | Returns pair of line numbers — first and last line of import section
-- if any import is in list.