Uses 1485K of libraries. Click here for Pure Java version (39189L/261K).
!include once #1034831 // Gazelle 22 Function Include for Testing set flag PingV3. svoid test_leftArrowScript_pinging() { embedded S countLoop(int n) { ret [[ i <- 0; while lessThan i ]] + n + [[ { i <- plus i 1 }; i ]]; } // Test that ping is called at least once per loop iteration var script1 = leftArrowParse(countLoop(5)); var script2 = leftArrowParse(countLoop(6)); long pingCount1 = countPingCalls(-> script1!); long pingCount2 = countPingCalls(-> script2!); printVars(+pingCount1, +pingCount2); assertTrue(pingCount2 > pingCount1); }
Began life as a copy of #1033988
download show line numbers debug dex old transpilations
Travelled to 3 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj
No comments. add comment
| Snippet ID: | #1034264 |
| Snippet name: | test_leftArrowScript_pinging |
| Eternal ID of this version: | #1034264/2 |
| Text MD5: | fa5cceb758d336bd2d7ee2aa0b667aa5 |
| Transpilation MD5: | 7f1927bffe8584926cac29f72254dd94 |
| Author: | stefan |
| Category: | javax |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2022-03-11 02:25:16 |
| Source code size: | 584 bytes / 17 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 698 / 888 |
| Version history: | 1 change(s) |
| Referenced in: | [show references] |