Stream: ideas

Topic: package header


view this post on Zulip Anton (Jul 04 2023 at 10:41):

In response to this topic.

Instead of

package [ParserCore, ParserCsv, ParserStr]
    packages [
        JsonDecode from "https://…/json/…",
        CodePt, Segment from "https://…/unicode/…",
    ]

I would prefer:

package
    exposes [
        ParserCore, ParserCsv, ParserStr
    ]
    imports [
        JsonDecode from "https://…/json/…",
        CodePt, Segment from "https://…/unicode/…",
    ]

Because it is more self-evident

view this post on Zulip Richard Feldman (Jul 04 2023 at 11:06):

so regarding exposes, historically we've had a concern that it's confusing that exposes exposes modules in the case of packages and values/types/abilities in the case of modules

that said, in the other (WIP) proposal I think there's a nice syntax that gets unlocked if we don't have an exposes keyword there, so maybe it's better to discuss in the full context once that part is no longer WIP :big_smile:


Last updated: Jun 16 2026 at 16:19 UTC