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

Assume schema rust definition #316

Closed
wants to merge 13 commits into from

Conversation

oflatt
Copy link
Member

@oflatt oflatt commented Feb 2, 2024

No description provided.

@oflatt oflatt changed the title Oflatt input schema rust Input schema rust definition Feb 2, 2024
@oflatt oflatt changed the title Input schema rust definition Assume schema rust definition Feb 2, 2024
BoolT,
UnitT,
/// Nested tuple types are not allowed.
TupleT(Vec<Rc<Type>>),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If nested tuples aren't allowed, can we make them unrepresentable, as in:

pub enum BaseType { Int, Bool, Unit }
pub enum Type { Prim(BaseType), Tuple(Vec<BaseType>) }

This way we also get to avoid boxing the tuple elements.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea

@oflatt oflatt marked this pull request as ready for review February 5, 2024 22:30
@oflatt
Copy link
Member Author

oflatt commented Feb 5, 2024

closing for now, will open a new PR for this

@oflatt oflatt closed this Feb 5, 2024
@oflatt oflatt deleted the oflatt-input-schema-rust branch May 6, 2024 19:16
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