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

8
LINES

< > BotCompany Repo | #1017575 // javaEvalOrInterpret - try to interpret code if possible; use callAndMake

JavaX fragment (include)

static O javaEvalOrInterpret(S code) {
  if (!canJavaInterpret(code)) ret javaEval(code);
  if (canQuickEval(code)) ret quickEval(code);
  Pair<S, L<S>> p = tok_parseFunctionCall(code);
  if (p != null)
    ret callAndMake(p.a, toObjectArray(map javaEvalOrInterpret(p.b)));
  ret javaEval(code);
}

Author comment

Began life as a copy of #1015630

download  show line numbers  debug dex  old transpilations   

Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1017575
Snippet name: javaEvalOrInterpret - try to interpret code if possible; use callAndMake
Eternal ID of this version: #1017575/3
Text MD5: f970f53375451baaee2cdb0ddf108820
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-01-15 17:38:23
Source code size: 304 bytes / 8 lines
Pitched / IR pitched: No / No
Views / Downloads: 381 / 431
Version history: 2 change(s)
Referenced in: #1006654 - Standard functions list 2 (LIVE, continuation of #761)
#1019609 - dm_javaEvalOrInterpret - try to interpret code if possible; use callAndMake
#1020891 - canJavaInterpret - check recursively
#1021642 - javaInterpret