1 | static new Map<S, Class> runTranslatorQuick_cache; |
2 | |
3 | static synchronized S runTranslatorQuick(S text, S translatorID) { |
4 | translatorID = formatSnippetID(translatorID); |
5 | Class c = runTranslatorQuick_cache.get(translatorID); |
6 | print("runTranslatorQuick " + programID() + " " + identityHashCode(main.class) + " CACHE " + identityHashCode(runTranslatorQuick_cache) + " " + structure(runTranslatorQuick_cache.keySet()) + " " + (c != null ? "CACHED" : "LOAD") + ": " + translatorID); |
7 | if (c == null) { |
8 | //printStackTrace(); |
9 | c = hotwire(translatorID); |
10 | print("runTranslatorQuick " + programID() + " " + identityHashCode(main.class) + " CACHE " + identityHashCode(runTranslatorQuick_cache) + " " + structure(runTranslatorQuick_cache.keySet()) + " STORE: " + translatorID + " " + identityHashCode(c)); |
11 | runTranslatorQuick_cache.put(translatorID, c); |
12 | } |
13 | |
14 | set(c, "mainJava", text); |
15 | callMain(c); |
16 | ret (S) get(c, "mainJava"); |
17 | } |
18 | |
19 | static L<S> runTranslatorQuick(L<S> tok, S translatorID) { |
20 | ret javaTok(runTranslatorQuick(join(tok), translatorID)); |
21 | } |
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1002425 |
Snippet name: | runTranslatorQuick |
Eternal ID of this version: | #1002425/1 |
Text MD5: | d1c5e7590645083ee290c7cff9742c86 |
Author: | stefan |
Category: | javax |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2016-02-22 03:12:33 |
Source code size: | 1080 bytes / 21 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 694 / 1941 |
Referenced in: | [show references] |