top | item 45706601 Global key-value metadata storage for Scryer Prolog 13 points| triska | 4 months ago |github.com 1 comment order hn newest shawa_a_a|4 months ago It's been a long time since I've programmed Prolog so I'm not sure if these ideas are even relevant (global state might be more than enough!) ; but at first impressions from the readme this really reminds me of ETShttps://www.erlang.org/doc/apps/stdlib/ets.htmlEssentially system-global state under named tables.Have/did you consider having named `env` instances? This would allow for say, feature flags to be kept in a `features` set of relations.You could also draw from Erlang's 'match specs' and query with a predicate over the keys.
shawa_a_a|4 months ago It's been a long time since I've programmed Prolog so I'm not sure if these ideas are even relevant (global state might be more than enough!) ; but at first impressions from the readme this really reminds me of ETShttps://www.erlang.org/doc/apps/stdlib/ets.htmlEssentially system-global state under named tables.Have/did you consider having named `env` instances? This would allow for say, feature flags to be kept in a `features` set of relations.You could also draw from Erlang's 'match specs' and query with a predicate over the keys.
shawa_a_a|4 months ago
https://www.erlang.org/doc/apps/stdlib/ets.html
Essentially system-global state under named tables.
Have/did you consider having named `env` instances? This would allow for say, feature flags to be kept in a `features` set of relations.
You could also draw from Erlang's 'match specs' and query with a predicate over the keys.