Skip to content

More options for deriving worlds #563

@sunfishcode

Description

@sunfishcode

Currently one can use include to derive one world from another, however I've been finding myself wanting more ways:

  • include_imports - Like include, but only includes imports
  • include_exports - Like include, but only includes exports
  • include_imports_exported - Like include_imports except translates the imports to exports
  • include_exports_imported - Like include_exports except translates the exports to imports

(suggestions for better syntax/naming welcome)

For example, include_imports would be useful when one wants to make a library component that can link to another component and otherwise occupy the same world. And include_imports_exported would be useful when one wants to make a world for the implementation that components of another world need.

In my current projects, I'm finding myself effectively working around the lack of include_imports by splitting out worlds that only have imports and than having the main worlds and library worlds include them. And for the lack of include_imports_exported I'm manually duplicating and translating imports in one world to exports in another.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions