Skip to content

Changing RawSpec/SpecValue #9

@Laar

Description

@Laar

The current implementation for the combined function and enum types is getting out of hand. For each mapping (Location, Definition, etc.) using SpecValues or ValueNames two functions need to be added to SpecValue. While the current design is simple and usable it does not scale well if more mappings are added. Thus something better is needed.

A better design would probably be to add something like

data BiMap f = BiMap (f EnumValue) (f FuncValue)

and using this to recreate the current mappings (using newtypes). Furthermore the addition of data Bi b = Bi b b (or something like that) could improve some double values (like the reuses filepaths), and possibly reduce the number of explicit type signatures.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions