-
Notifications
You must be signed in to change notification settings - Fork 2
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
423 custom rules #432
423 custom rules #432
Conversation
@deemp Thanks for the review! You've earned +35 points for this: +25 as a basis; +5 for 876 hits-of-code; +5 for 0 comments. Your running balance is +5. |
@fizruk Thanks for the contribution! You've earned +5 points for this: +20 as a basis; +5 for 876 hits-of-code; -7 for too many hits-of-code (876 >= 100); -15 for way too many hits-of-code (876 >= 400); -5 for 0 comments; +7 to give you at least something. Please, keep them coming. Your running balance is +30. |
This PR aims to close #423. However, the implementation diverges with the initial proposal. Here is what is in this PR:
streams.yaml
with the example rule equipped with with a passing test, matching Custom rules. Iteration 2 #423 (comment)apply_in_abstract_subformations
option to maintain correctness foryegor.yaml
rules)forall
to keep track of all metavariables for extra safety (force in the future, see Force explicit declaration of pattern variables #441)Here are the differences with the initial proposal in #423:
!
and we do not (yet) distinguish their types (attribute/object/binding/etc.).t1 * t2
we use one-hole context patterns!C1 [1| obj |1]
. The notation is subject to change (in particular, we may allowobj * !C1
, for example). Importantly, the one-hole context pattern allows to match against objects in application arguments.forall
is implicit: all metavariables used in the pattern are automatically put under theforall
.exists
is replaced withfresh
(and can only yield fresh attributes).PR-Codex overview
This PR updates object and meta ID handling in the EO Phi normalizer.
Detailed summary
MetaId
with specific ID types likeLabelMetaId
MetaTailContext
and updated related functions