Ticket #168 (new defect)

Opened 4 years ago

Last modified 4 years ago

Module exporter re-exports projections it has imported

Reported by: erikd Owned by:
Priority: blocker Milestone: 0.1.3
Component: Unknown Version: 0.1.2
Keywords: Cc:


With a simple module that defines a new projection on Data.List like this:

module Foo

project List where
	count = length

the exporter (src/Module/Exporter.hs) for this exports the following proections for Foo:

project Data.List.List %rDK125 where
        x = project_List_x;
        xs = project_List_xs;
        ref_x = project_List_ref_x;
        ref_xs = project_List_ref_xs;
        count = project_List_count;

where the first 4 are the projections already defined in Data.List. Only the last projection (count) should actually be exported from this module.

Change History

Changed 4 years ago by erikd

With recent refactorings by Ben, and an updated test by me, the error reported is now:

ddc: "./test/Broken-skip/T168-ModuleExporter/Foo.di" (line 60, column 19):
unexpected Data.List
expecting pVar_withKind

The module importer is basically complaining about a type variable being fully qualified. Its pretty easy to modify pVar_withKind to accept a qualified variable name but that is not actually the solution, because what the importer is complaining about should never have been exported in the first place.

This should be easier to fix once Ben completes the module exporter refactorings.

Note: See TracTickets for help on using tickets.