reader.setInstanceVariable("@errors", runtime.newArray());
IRubyObject url = context.nil;
if (args.length > 1) url = args[1];
if (args.length > 2) reader.setInstanceVariable("@encoding", args[2]);
Options options;
if (args.length > 3) {
options = new ParserContext.Options((Long)args[3].toJava(Long.class));
} else {
// use the default options RECOVER | NONET
options = new ParserContext.Options(2048 | 1);