- Object[] rest = new Object[numArgs - 3];
- Object a0 = match.toString();
- Object a1 = null;
- Object a2 = null;
- for(int j=1;j<=n;j++)
- switch(j) {
- case 1: a1 = match.toString(j); break;
- case 2: a2 = match.toString(j); break;
- default: rest[j - 3] = match.toString(j); break;
- }
- switch(numArgs) {
- case 3:
- a1 = N(match.getStartIndex());
- a2 = s;
- break;
- case 4:
- a2 = N(match.getStartIndex());
- rest[0] = s;
- break;
- default:
- rest[rest.length - 2] = N(match.getStartIndex());
- rest[rest.length - 1] = s;
- }
+ JS[] args = new JS[3 + n];
+ args[0] = JSU.S(match.toString());
+ args[1] = null;
+ args[2] = null;
+ for(int j=1;j<=n;j++) args[j] = JSU.S(match.toString(j));
+ args[args.length - 2] = JSU.N(match.getStartIndex());
+ args[args.length - 1] = JSU.S(s);