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

Allow heterogeneous sets #140

Open
divarvel opened this issue Jun 12, 2023 · 0 comments
Open

Allow heterogeneous sets #140

divarvel opened this issue Jun 12, 2023 · 0 comments
Milestone

Comments

@divarvel
Copy link
Collaborator

divarvel commented Jun 12, 2023

The spec mentions in a single place that sets should only contain elements of the same type, but nothing else in the spec mentions it or even relies on this property.

as for implementations:

  • biscuit-rust prevents it in the parser and the protobuf deserialization layer, but still allows through parameter substitution or manual AST building.
  • biscuit-haskell does not prevent it

in any case, evaluation is defined for heterogeneous sets (set operations care about equality of elements, which is defined on heterogeneous values if we consider datalog terms as unityped).

I think the homogeneous set restriction is arbitrary and could be lifted. If we want to keep this restriction, we should make sure heterogeneous sets can't be created at all.

One current limitation in biscuit-rust is that it prevents using parameter interpolation within a set: ["a", {b}] will fail to parse.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Implementation
Development

No branches or pull requests

1 participant