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

Some small Pact feature suggestions #1140

Open
11 tasks
jwiegley opened this issue Feb 8, 2023 · 0 comments
Open
11 tasks

Some small Pact feature suggestions #1140

jwiegley opened this issue Feb 8, 2023 · 0 comments

Comments

@jwiegley
Copy link
Contributor

jwiegley commented Feb 8, 2023

This list is from nuwu on Discord (https://discord.com/channels/502858632178958377/524762252734365696/1072905294604161056):

  • Governance delegate: (module app G (defcap G () true)) (module awa app (defun f (x) x)). Doesn't inline, latter module always adopts the governance of former
  • Keysets could be scoped by the (namespace) declaration, in order to allow flexible test codes
  • Nested object merge: (+ { 'a: { 'b: 2 } } { 'a: { 'c: 3 } }) = { 'a: { 'b: 2, 'c: 3 } }
  • Nested binds / deconstruct: (bind ob { 'a := { 'b := b } } ...)
  • Unclear how to manage database keys on tree data structure. Should node reference parents (space) or implement a string split function deriving parent from current node key (time)? Seems most implementations store redundant self-referential keys in tables, but it seems wasteful.
  • Typed numeric: x:number{token-bun}, which may carry models, precision, allowed values, etc, potentially enforced in the definition of their constructor
  • "Subset of" interface: (interface a (defun f:decimal ()) (defun g:decimal ())) (interface b (infer a [ f ])). a "implies" b.
  • For some reason, (let ((_:object{schema} o)) 0) behaves oddly
  • (pure) function: unlike (try) propagate errors but prohibits database writes. i.e. (pure (modref::fn x))
  • Unclear why, but the final default branch of (cond) doesn't allow s-expression, sometimes
  • Flexible inference: fix empty lists randomly resulting in type errors
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

No branches or pull requests

1 participant