biscuit-rust icon indicating copy to clipboard operation
biscuit-rust copied to clipboard

rework `builder` helpers

Open divarvel opened this issue 4 months ago • 1 comments

biscuit_auth::builder features a few functions aimed at making it easier to create datalog code (rule, check, etc).

These helpers are a bit behind in terms of language features (eg check does not provide a way to use expressions or scopes). Some terminology is dated (eg constrained_rule). There is also no helper for expressions, even though they are harder to construct (since Expressions are directly encoded with opcodes). This has not been a big issue this far thanks to macros, which can replace builder code in many cases (ie when the datalog structure is static), but there is still the need for dynamically generated datalog.

Adding stuff would not be too hard, but some things should be changed as well, and that would be a breaking change. Maybe we could add a new dedicated module, while deprecating the existing outdated helpers.

divarvel avatar Aug 12 '25 15:08 divarvel