Stream: beginners

Topic: effects in platforms


view this post on Zulip Richard Feldman (Feb 04 2022 at 23:43):

PSA: the syntax for defining effects in platforms has changed on trunk!

now they're in a separate hosted module - for example, here's the CLI example:

where effects used to be defined

where they're now defined

view this post on Zulip jan kili (Feb 05 2022 at 00:56):

Nice! Very clean. Does this enable anything new? (spreading effect definitions across multiple files?)

view this post on Zulip Richard Feldman (Feb 05 2022 at 03:10):

yes! It means it's now possible to have type aliases in other interface modules and use them both in effects definitions as well as in the platform's public API

view this post on Zulip Richard Feldman (Feb 05 2022 at 03:11):

this is particularly nice with error types that get used in Tasks, and it was previously impossible because trying to do it would require a cyclic import


Last updated: Jul 06 2025 at 12:14 UTC