Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

Editing Snippet ID: #1018313
Snippet name:
Category, Type:
Content:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
static void nlLogic_iterate_withOnFail(final NLLogicChecker_v2 c, 
Exp e, final NLLogicChecker_v2.Matching m, final Runnable onMatch, 
final VF1<Exp> onFail) {
  final new Flag anyResults;
  
  if (e cast And) {
    final Exp b = e.b;
    c.iterate_single(e.a, m, r {
      anyResults.raise();
      nlLogic_iterate_withOnFail(c, b, m, onMatch, onFail)
    });
  } else
    c.iterate_single(e, m, r {
      anyResults.raise();
      callF(onMatch);
    });
    
  if (!anyResults.isUp())
    callF(onFail, e);
}
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Comment:
Public (visible to everyone):
Created: 2018-09-19 16:37:55

This page without fancy editor.