Skip to content

Commit

Permalink
Re-enable the updated rule 5
Browse files Browse the repository at this point in the history
  • Loading branch information
aabounegm committed Mar 4, 2024
1 parent d595f2d commit 546807a
Showing 1 changed file with 18 additions and 11 deletions.
29 changes: 18 additions & 11 deletions eo-phi-normalizer/test/eo/phi/rules/yegor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -94,17 +94,24 @@ rules:
# when: []
# tests: []

# - name: Rule 5
# description: 'ξ-dispatch'
# pattern: |
# ⟦ !a ↦ ξ.!b, !B ⟧
# result: |
# ⟦ !a ↦ ⟦ !B ⟧.!b, !B ⟧
# when: []
# tests:
# - name: Replaces ξ with the actual object
# input: '⟦ a ↦ ⟦ ⟧, x ↦ ξ.a, b ↦ ⟦ ⟧ ⟧'
# output: ['⟦ a ↦ ⟦ ⟧, x ↦ ⟦ a ↦ ⟦ ⟧, b ↦ ⟦ ⟧ ⟧.a, b ↦ ⟦ ⟧ ⟧']
- name: Rule 5
description: 'ξ-dispatch'
context:
current_object: '⟦ !a ↦ !obj, !B ⟧'
current_attribute: '!a'
pattern: |
ξ
result: |
⟦ !B ⟧
when:
- present_attrs:
attrs: ['ν', 'σ', 'ρ']
bindings: ['!B']
tests:
- name: Replaces ξ with the actual object
input: '⟦ a ↦ ⟦ ⟧, x ↦ ξ.a, ν ↦ ⟦ ⟧, σ ↦ ⟦ ⟧, ρ ↦ ⟦ ⟧ ⟧'
output:
- '⟦ a ↦ ⟦ ⟧, x ↦ ⟦ a ↦ ⟦ ⟧, ν ↦ ⟦ ⟧, σ ↦ ⟦ ⟧, ρ ↦ ⟦ ⟧ ⟧.a, ν ↦ ⟦ ⟧, σ ↦ ⟦ ⟧, ρ ↦ ⟦ ⟧ ⟧',

- name: Rule 6
description: 'Accessing an α-binding'
Expand Down

0 comments on commit 546807a

Please sign in to comment.