We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
The following WyRL program:
term X term Y term Z define YZ as Y | Z term C{X,YZ...} reduce C{X x,Y,YZ... yzs}: => C(x++yzs)
Generates the following probe() code:
probe()
public final void probe(Automaton automaton, int target, List activations) { int r0 = target; Automaton.State s0 = automaton.get(r0); if(s0.kind == K_C) { Automaton.Term t0 = (Automaton.Term) s0; int r1 = t0.contents; Automaton.State s1 = automaton.get(r1); Automaton.Collection c1 = (Automaton.Collection) s1; if(c1.size() >= 2) { for(int r3=0;r3!=c1.size();++r3) { int r2 = c1.get(r3); for(int r5=0;r5!=c1.size();++r5) { if(r5 == r3) { continue; } int r4 = c1.get(r5); if(Runtime.accepts(type1,automaton,automaton.get(r4), SCHEMA)) { int[] state = {r0, r1, r2, r3, r4, r5, 0}; activations.add(new Reduction.Activation(this,null,state)); } } } } } }
If we look very carefully, we can notice that r2 (which represents x) is never tested against the type X. This generates potentially invalid matches.
r2
x
X
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The following WyRL program:
Generates the following
probe()
code:If we look very carefully, we can notice that
r2
(which representsx
) is never tested against the typeX
. This generates potentially invalid matches.The text was updated successfully, but these errors were encountered: