Skip to content

Conversation

@johanneshorner
Copy link

This is mostly a draft on how I'd imagine the Host pattern to look like. @Anton-4 and @lukewilliamboswell is this what the two of you had in mind?

What about the fields of the Host type? The way i wrote it here these are public to the consuming roc application which we probably don't want?

@lukewilliamboswell
Copy link
Collaborator

Yeah that is what I was thinking... how does it feel to you? do you think it's the right direction?

@johanneshorner
Copy link
Author

I'm not sure yet. I guess you have the most control this way if you pass around a Host object to every function. But as UserData is also passed around in RocOps implicitly already (and therefore the platform already has a way to store data) I don't quite see yet what the "pass around Host" pattern gains here?
You don't really gain anything but lose on the ergonomics side of things as the user has to pass Host everywhere.

This is just a feeling though. I would have to write some Library code to really get a good impression of the ergonomics.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants