Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(Feature) Module bundles or Partial modules #175

Open
skejeton opened this issue Jun 29, 2022 · 2 comments
Open

(Feature) Module bundles or Partial modules #175

skejeton opened this issue Jun 29, 2022 · 2 comments
Labels
enhancement New feature or request

Comments

@skejeton
Copy link
Contributor

skejeton commented Jun 29, 2022

Sometimes modules can get quite big, and it makes sense to separate them. Sometimes modules can just be bundles of other modules.
In my case the UI module handles many different things, and keeping it all in one file is pretty inconvenient.

The idea is that you are able to "load" a module into the module itself. This essentially puts the loaded modules to the root (the module that loads) modules namespace. This is preferably not a text substitution to retain compatibility between bundle included and standalone modules.

load (
  "ui_core.um"; "ui_windows.um"; "ui_widgets.um"; "ui_rectcut.um" // et cetera
)

This also relates to #173 because this would essentially solve the problem by allowing you to wrap the conflicting modules into a bundle. (Mind you, this feature is just another feature in the bucket of ideas, these problems can be addressed one way or another)

@skejeton skejeton changed the title (Feature) Partial modules (Feature) Module bundles / Partial modules Jun 29, 2022
@skejeton skejeton changed the title (Feature) Module bundles / Partial modules (Feature) Module bundles or Partial modules Jun 29, 2022
@vtereshkov vtereshkov added the enhancement New feature or request label Jun 29, 2022
@vtereshkov
Copy link
Owner

@skejeton I think it will be difficult for a user to distinguish between load and import clauses. Moreover, the file system already provides a nice bundling mechanism -- folders. So I would rather consider something like import "ui/*".

@skejeton
Copy link
Contributor Author

I agree, import "ui/*" does sound pretty nice

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants