b.putAndTriggerTraps(b.get(JSU.S("numchildren")), kid);
}
- if (script != null) JSU.cloneWithNewGlobalScope(script, pis).call(callempty);
+ if (script != null) JSU.cloneWithNewGlobalScope(script, pis).call(null, callempty);
for(int i=0; keys != null && i < keys.length; i++) {
if (keys[i] == null) continue;
public TemplateHelper(String sourceName, JS s, Ibex ibex) throws XML.Exn, IOException, JSExn {
this.sourceName = sourceName;
this.ibex = ibex;
- InputStream is = s.getInputStream();
+ InputStream is = JSU.getInputStream(s);
Ibex.Blessing b = Ibex.Blessing.getBlessing(s).parent;
while(b != null) {
if(b.parentkey != null) initial_uri = JSU.toString(b.parentkey) + (initial_uri.equals("") ? "" : "." + initial_uri);
JS staticScript = parseScript(static_content, static_content_start);
t.staticObject = new JS.Obj();
JS staticScope = new PerInstantiationScope(null, ibex, null, t.staticObject);
- if (staticScript != null) JSU.cloneWithNewGlobalScope(staticScript, staticScope).call(callempty);
+ if (staticScript != null) JSU.cloneWithNewGlobalScope(staticScript, staticScope).call(null, callempty);
}
private JS parseScript(StringBuffer content, int content_start) throws IOException {
// sort the attributes lexicographically
Basket.Array.sort(keys, vals, new Basket.CompareFunc() {
public int compare(Object a, Object b) { return ((String)a).compareTo((String)b); }
- }, 0, keys.size());
+ }, 0, keys.size() - 1);
t.keys = new JS[keys.size()];
t.vals = new JS[vals.size()];