Libraryless. Click here for Pure Java version (22767L/140K).
1 | interface IStackWithOptions extends IVStack { |
2 | // declare a choice point for backtracking |
3 | // (or a probabilistic choice point if it's a PStack) |
4 | default <B extends VStack.Computable> void options(B currentFrame, IVF1<B>... options) { |
5 | options(currentFrame, arrayIterator(options)); |
6 | } |
7 | |
8 | <B extends VStack.Computable> void options(B currentFrame, Iterable<IVF1<B>> options); |
9 | |
10 | // if options list is empty, return null |
11 | default <B extends VStack.Computable> void optionsOrReturn(B currentFrame, Cl<IVF1<B>> options) { |
12 | if (empty(options)) |
13 | _return(); |
14 | else |
15 | options(currentFrame, options); |
16 | } |
17 | } |
Began life as a copy of #1035395
download show line numbers debug dex old transpilations
Travelled to 3 computer(s): ekrmjmnbrukm, mowyntqkapby, mqqgnosmbjvj
No comments. add comment
Snippet ID: | #1035429 |
Snippet name: | IStackWithOptions - base interface for BStack and PStack |
Eternal ID of this version: | #1035429/9 |
Text MD5: | ba643f49f23dbb0ed008a1280c293d3b |
Transpilation MD5: | 4f9c59c0f4b44c77e92c4002c32d6ffe |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2022-09-01 23:28:25 |
Source code size: | 640 bytes / 17 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 194 / 264 |
Version history: | 8 change(s) |
Referenced in: | [show references] |