You could try replacing (0 (*)) with (jT (*)) or restructure it into a SETCHILD rule.
(0 (*)) is a contextual target, which is evaluated as a contextual test and thus does not automatically evaluate to the target like the other (*) does and instead tries to create a self-loop. Daniel On Fri, Dec 20, 2024 at 5:25 PM Paul Meurer <[email protected]> wrote: > > Sorry, the last line should have read: > > This does work and gives me C -> A, B -> A. (This is however not what I need.) > > > > Am 20. 12. 24 um 23:09 schrieb Paul Meurer <[email protected]>: > > > > Hi, > > > > I am trying to do several attachments in a WITH block. > > > > In the sentence > > > > A B C > > > > I want to get > > > > C -> A > > B -> C > > > > I try this rule set: > > > > WITH ("C") > > IF (-2 ("A")) > > (-1 ("B")) > > (NOT p (*)) { > > SETPARENT (*) TO (jC1 (*)) ; > > SETPARENT _C2_ TO (0 (*)) ; > > } ; > > > > but it does only do the first attachment C -> A. > > > > Is there something wrong with my syntax; can this be done at all? > > > > I tried a variant: > > > > WITH ("C") > > IF (-2 ("A")) > > (-1 ("B")) > > (NOT p (*)) { > > SETPARENT (*) TO (jC1 (*)) ; > > SETPARENT _C2_ TO (jC1 (*)) ; > > } ; > > > > This does work and gives me C -> A, C -> B. (This is however not what I > > need.) > > > > - Paul Meurer > > -- > You received this message because you are subscribed to the Google Groups > "Constraint Grammar" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion visit > https://groups.google.com/d/msgid/constraint-grammar/47DB168A-AB87-489E-865B-2B1F66121D48%40uib.no. -- Daniel Swanson, Certified Geek -- You received this message because you are subscribed to the Google Groups "Constraint Grammar" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion visit https://groups.google.com/d/msgid/constraint-grammar/CALFoTbTcjr%2BQ7YLTWfaOKabJkwkfDOsSnaNQL_DNt%3DT5KvWU_g%40mail.gmail.com.
