1 | static <A> A withDeepReturn(IVF1<DeepReturnSite<A>> r) { |
2 | temp new DeepReturnSite<A> site; |
3 | try { |
4 | r.get(site); |
5 | } catch e { |
6 | e = innerException(e); |
7 | if (e instanceof DeepReturn && e/DeepReturn.site == site) |
8 | ret site!; |
9 | else |
10 | rethrow(e); |
11 | } |
12 | null; |
13 | } |
Began life as a copy of #1018342
download show line numbers debug dex old transpilations
Travelled to 7 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt, xrpafgyirdlv
No comments. add comment
Snippet ID: | #1028835 |
Snippet name: | withDeepReturn - like withCancelPoint, but allowing a return value |
Eternal ID of this version: | #1028835/2 |
Text MD5: | c750b1ada090c2b9f972ccfdffe07cab |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2020-07-09 15:25:09 |
Source code size: | 289 bytes / 13 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 208 / 240 |
Version history: | 1 change(s) |
Referenced in: | [show references] |