smparkes-johnson 1.1.2.3
Sign up to get free protection for your applications and to get access to all the features.
- data/.autotest +14 -0
- data/CHANGELOG.rdoc +21 -0
- data/Manifest.txt +1077 -0
- data/README.rdoc +51 -0
- data/Rakefile +140 -0
- data/bin/johnson +106 -0
- data/ext/spidermonkey/context.c +116 -0
- data/ext/spidermonkey/context.h +19 -0
- data/ext/spidermonkey/conversions.c +354 -0
- data/ext/spidermonkey/conversions.h +31 -0
- data/ext/spidermonkey/debugger.c +234 -0
- data/ext/spidermonkey/debugger.h +10 -0
- data/ext/spidermonkey/extconf.rb +32 -0
- data/ext/spidermonkey/extensions.c +37 -0
- data/ext/spidermonkey/extensions.h +12 -0
- data/ext/spidermonkey/global.c +40 -0
- data/ext/spidermonkey/global.h +11 -0
- data/ext/spidermonkey/idhash.c +16 -0
- data/ext/spidermonkey/idhash.h +8 -0
- data/ext/spidermonkey/immutable_node.c +1153 -0
- data/ext/spidermonkey/immutable_node.c.erb +523 -0
- data/ext/spidermonkey/immutable_node.h +22 -0
- data/ext/spidermonkey/jroot.h +197 -0
- data/ext/spidermonkey/js_land_proxy.c +610 -0
- data/ext/spidermonkey/js_land_proxy.h +20 -0
- data/ext/spidermonkey/ruby_land_proxy.c +611 -0
- data/ext/spidermonkey/ruby_land_proxy.h +38 -0
- data/ext/spidermonkey/runtime.c +396 -0
- data/ext/spidermonkey/runtime.h +27 -0
- data/ext/spidermonkey/spidermonkey.c +22 -0
- data/ext/spidermonkey/spidermonkey.h +29 -0
- data/ext/tracemonkey/context.cc +125 -0
- data/ext/tracemonkey/context.h +19 -0
- data/ext/tracemonkey/conversions.cc +355 -0
- data/ext/tracemonkey/conversions.h +32 -0
- data/ext/tracemonkey/debugger.cc +234 -0
- data/ext/tracemonkey/debugger.h +10 -0
- data/ext/tracemonkey/extconf.rb +37 -0
- data/ext/tracemonkey/extensions.cc +37 -0
- data/ext/tracemonkey/extensions.h +12 -0
- data/ext/tracemonkey/global.cc +40 -0
- data/ext/tracemonkey/global.h +11 -0
- data/ext/tracemonkey/idhash.cc +16 -0
- data/ext/tracemonkey/idhash.h +8 -0
- data/ext/tracemonkey/immutable_node.cc +1199 -0
- data/ext/tracemonkey/immutable_node.cc.erb +559 -0
- data/ext/tracemonkey/immutable_node.h +22 -0
- data/ext/tracemonkey/jroot.h +215 -0
- data/ext/tracemonkey/js_land_proxy.cc +610 -0
- data/ext/tracemonkey/js_land_proxy.h +20 -0
- data/ext/tracemonkey/ruby_land_proxy.cc +611 -0
- data/ext/tracemonkey/ruby_land_proxy.h +38 -0
- data/ext/tracemonkey/runtime.cc +454 -0
- data/ext/tracemonkey/runtime.h +27 -0
- data/ext/tracemonkey/split_global.cc +392 -0
- data/ext/tracemonkey/split_global.h +11 -0
- data/ext/tracemonkey/tracemonkey.cc +23 -0
- data/ext/tracemonkey/tracemonkey.h +32 -0
- data/lib/johnson/cli/options.rb +67 -0
- data/lib/johnson/cli.rb +8 -0
- data/lib/johnson/error.rb +4 -0
- data/lib/johnson/js/cli.js +30 -0
- data/lib/johnson/js/prelude.js +118 -0
- data/lib/johnson/nodes/binary_node.rb +65 -0
- data/lib/johnson/nodes/for.rb +14 -0
- data/lib/johnson/nodes/for_in.rb +12 -0
- data/lib/johnson/nodes/function.rb +13 -0
- data/lib/johnson/nodes/list.rb +28 -0
- data/lib/johnson/nodes/node.rb +68 -0
- data/lib/johnson/nodes/ternary_node.rb +20 -0
- data/lib/johnson/nodes.rb +7 -0
- data/lib/johnson/parser/syntax_error.rb +13 -0
- data/lib/johnson/parser.rb +22 -0
- data/lib/johnson/ruby_land_proxy.rb +81 -0
- data/lib/johnson/runtime.rb +141 -0
- data/lib/johnson/spidermonkey/context.rb +10 -0
- data/lib/johnson/spidermonkey/debugger.rb +67 -0
- data/lib/johnson/spidermonkey/immutable_node.rb +282 -0
- data/lib/johnson/spidermonkey/js_land_proxy.rb +64 -0
- data/lib/johnson/spidermonkey/mutable_tree_visitor.rb +242 -0
- data/lib/johnson/spidermonkey/ruby_land_proxy.rb +17 -0
- data/lib/johnson/spidermonkey/runtime.rb +92 -0
- data/lib/johnson/spidermonkey.rb +12 -0
- data/lib/johnson/tracemonkey/context.rb +10 -0
- data/lib/johnson/tracemonkey/debugger.rb +67 -0
- data/lib/johnson/tracemonkey/immutable_node.rb +282 -0
- data/lib/johnson/tracemonkey/js_land_proxy.rb +64 -0
- data/lib/johnson/tracemonkey/mutable_tree_visitor.rb +242 -0
- data/lib/johnson/tracemonkey/ruby_land_proxy.rb +17 -0
- data/lib/johnson/tracemonkey/runtime.rb +98 -0
- data/lib/johnson/tracemonkey.rb +13 -0
- data/lib/johnson/visitable.rb +16 -0
- data/lib/johnson/visitors/dot_visitor.rb +169 -0
- data/lib/johnson/visitors/ecma_visitor.rb +323 -0
- data/lib/johnson/visitors/enumerating_visitor.rb +15 -0
- data/lib/johnson/visitors/sexp_visitor.rb +174 -0
- data/lib/johnson/visitors/visitor.rb +91 -0
- data/lib/johnson/visitors.rb +5 -0
- data/lib/johnson.rb +53 -0
- data/test/generic/johnson_test.rb +16 -0
- data/test/generic/parser_test.rb +276 -0
- data/test/helper.rb +82 -0
- data/test/johnson/generic/browser_test.rb +43 -0
- data/test/johnson/generic/conversions/array_test.rb +70 -0
- data/test/johnson/generic/conversions/boolean_test.rb +17 -0
- data/test/johnson/generic/conversions/callable_test.rb +34 -0
- data/test/johnson/generic/conversions/file_test.rb +15 -0
- data/test/johnson/generic/conversions/helper.rb +1 -0
- data/test/johnson/generic/conversions/nil_test.rb +20 -0
- data/test/johnson/generic/conversions/number_test.rb +34 -0
- data/test/johnson/generic/conversions/regexp_test.rb +24 -0
- data/test/johnson/generic/conversions/string_test.rb +38 -0
- data/test/johnson/generic/conversions/struct_test.rb +15 -0
- data/test/johnson/generic/conversions/symbol_test.rb +19 -0
- data/test/johnson/generic/conversions/thread_test.rb +24 -0
- data/test/johnson/generic/default_test.rb +12 -0
- data/test/johnson/generic/error_test.rb +9 -0
- data/test/johnson/generic/extensions_test.rb +56 -0
- data/test/johnson/generic/helper.rb +1 -0
- data/test/johnson/generic/nodes/array_literal_test.rb +57 -0
- data/test/johnson/generic/nodes/array_node_test.rb +26 -0
- data/test/johnson/generic/nodes/binary_node_test.rb +61 -0
- data/test/johnson/generic/nodes/bracket_access_test.rb +16 -0
- data/test/johnson/generic/nodes/delete_test.rb +11 -0
- data/test/johnson/generic/nodes/do_while_test.rb +12 -0
- data/test/johnson/generic/nodes/dot_accessor_test.rb +15 -0
- data/test/johnson/generic/nodes/export_test.rb +11 -0
- data/test/johnson/generic/nodes/for_test.rb +54 -0
- data/test/johnson/generic/nodes/function_test.rb +71 -0
- data/test/johnson/generic/nodes/helper.rb +1 -0
- data/test/johnson/generic/nodes/if_test.rb +51 -0
- data/test/johnson/generic/nodes/import_test.rb +15 -0
- data/test/johnson/generic/nodes/label_test.rb +19 -0
- data/test/johnson/generic/nodes/let_test.rb +31 -0
- data/test/johnson/generic/nodes/object_literal_test.rb +110 -0
- data/test/johnson/generic/nodes/return_test.rb +16 -0
- data/test/johnson/generic/nodes/semi_test.rb +8 -0
- data/test/johnson/generic/nodes/switch_test.rb +55 -0
- data/test/johnson/generic/nodes/ternary_test.rb +25 -0
- data/test/johnson/generic/nodes/throw_test.rb +9 -0
- data/test/johnson/generic/nodes/try_node_test.rb +89 -0
- data/test/johnson/generic/nodes/typeof_test.rb +11 -0
- data/test/johnson/generic/nodes/unary_node_test.rb +23 -0
- data/test/johnson/generic/nodes/void_test.rb +11 -0
- data/test/johnson/generic/nodes/while_test.rb +26 -0
- data/test/johnson/generic/nodes/with_test.rb +10 -0
- data/test/johnson/generic/prelude_test.rb +79 -0
- data/test/johnson/generic/runtime_test.rb +140 -0
- data/test/johnson/generic/version_test.rb +13 -0
- data/test/johnson/generic/visitors/dot_visitor_test.rb +39 -0
- data/test/johnson/generic/visitors/enumerating_visitor_test.rb +12 -0
- data/test/johnson/generic/visitors/helper.rb +1 -0
- data/test/johnson/spidermonkey/context_test.rb +21 -0
- data/test/johnson/spidermonkey/immutable_node_test.rb +34 -0
- data/test/johnson/spidermonkey/js_land_proxy_test.rb +277 -0
- data/test/johnson/spidermonkey/ruby_land_proxy_test.rb +270 -0
- data/test/johnson/spidermonkey/runtime_test.rb +41 -0
- data/test/johnson/tracemonkey/context_test.rb +21 -0
- data/test/johnson/tracemonkey/immutable_node_test.rb +34 -0
- data/test/johnson/tracemonkey/js_land_proxy_test.rb +277 -0
- data/test/johnson/tracemonkey/ruby_land_proxy_test.rb +270 -0
- data/test/johnson/tracemonkey/runtime_test.rb +41 -0
- data/test/johnson/tracemonkey/split_global_test.rb +32 -0
- data/vendor/spidermonkey/.cvsignore +9 -0
- data/vendor/spidermonkey/Makefile.in +449 -0
- data/vendor/spidermonkey/Makefile.ref +365 -0
- data/vendor/spidermonkey/README.html +820 -0
- data/vendor/spidermonkey/SpiderMonkey.rsp +12 -0
- data/vendor/spidermonkey/Y.js +19 -0
- data/vendor/spidermonkey/build.mk +43 -0
- data/vendor/spidermonkey/config/AIX4.1.mk +65 -0
- data/vendor/spidermonkey/config/AIX4.2.mk +64 -0
- data/vendor/spidermonkey/config/AIX4.3.mk +65 -0
- data/vendor/spidermonkey/config/Darwin.mk +83 -0
- data/vendor/spidermonkey/config/Darwin1.3.mk +81 -0
- data/vendor/spidermonkey/config/Darwin1.4.mk +41 -0
- data/vendor/spidermonkey/config/Darwin5.2.mk +81 -0
- data/vendor/spidermonkey/config/Darwin5.3.mk +81 -0
- data/vendor/spidermonkey/config/HP-UXB.10.10.mk +77 -0
- data/vendor/spidermonkey/config/HP-UXB.10.20.mk +77 -0
- data/vendor/spidermonkey/config/HP-UXB.11.00.mk +80 -0
- data/vendor/spidermonkey/config/IRIX.mk +87 -0
- data/vendor/spidermonkey/config/IRIX5.3.mk +44 -0
- data/vendor/spidermonkey/config/IRIX6.1.mk +44 -0
- data/vendor/spidermonkey/config/IRIX6.2.mk +44 -0
- data/vendor/spidermonkey/config/IRIX6.3.mk +44 -0
- data/vendor/spidermonkey/config/IRIX6.5.mk +44 -0
- data/vendor/spidermonkey/config/Linux_All.mk +103 -0
- data/vendor/spidermonkey/config/Mac_OS10.0.mk +82 -0
- data/vendor/spidermonkey/config/OSF1V4.0.mk +72 -0
- data/vendor/spidermonkey/config/OSF1V5.0.mk +69 -0
- data/vendor/spidermonkey/config/SunOS4.1.4.mk +101 -0
- data/vendor/spidermonkey/config/SunOS5.10.mk +50 -0
- data/vendor/spidermonkey/config/SunOS5.3.mk +91 -0
- data/vendor/spidermonkey/config/SunOS5.4.mk +92 -0
- data/vendor/spidermonkey/config/SunOS5.5.1.mk +44 -0
- data/vendor/spidermonkey/config/SunOS5.5.mk +87 -0
- data/vendor/spidermonkey/config/SunOS5.6.mk +89 -0
- data/vendor/spidermonkey/config/SunOS5.7.mk +44 -0
- data/vendor/spidermonkey/config/SunOS5.8.mk +44 -0
- data/vendor/spidermonkey/config/SunOS5.9.mk +44 -0
- data/vendor/spidermonkey/config/WINNT4.0.mk +117 -0
- data/vendor/spidermonkey/config/WINNT5.0.mk +117 -0
- data/vendor/spidermonkey/config/WINNT5.1.mk +117 -0
- data/vendor/spidermonkey/config/WINNT5.2.mk +117 -0
- data/vendor/spidermonkey/config/WINNT6.0.mk +117 -0
- data/vendor/spidermonkey/config/dgux.mk +64 -0
- data/vendor/spidermonkey/config.mk +192 -0
- data/vendor/spidermonkey/editline/Makefile.ref +144 -0
- data/vendor/spidermonkey/editline/README +83 -0
- data/vendor/spidermonkey/editline/editline.3 +175 -0
- data/vendor/spidermonkey/editline/editline.c +1369 -0
- data/vendor/spidermonkey/editline/editline.h +135 -0
- data/vendor/spidermonkey/editline/sysunix.c +182 -0
- data/vendor/spidermonkey/editline/unix.h +82 -0
- data/vendor/spidermonkey/fdlibm/.cvsignore +7 -0
- data/vendor/spidermonkey/fdlibm/Makefile.in +127 -0
- data/vendor/spidermonkey/fdlibm/Makefile.ref +192 -0
- data/vendor/spidermonkey/fdlibm/e_acos.c +147 -0
- data/vendor/spidermonkey/fdlibm/e_acosh.c +105 -0
- data/vendor/spidermonkey/fdlibm/e_asin.c +156 -0
- data/vendor/spidermonkey/fdlibm/e_atan2.c +165 -0
- data/vendor/spidermonkey/fdlibm/e_atanh.c +110 -0
- data/vendor/spidermonkey/fdlibm/e_cosh.c +133 -0
- data/vendor/spidermonkey/fdlibm/e_exp.c +202 -0
- data/vendor/spidermonkey/fdlibm/e_fmod.c +184 -0
- data/vendor/spidermonkey/fdlibm/e_gamma.c +71 -0
- data/vendor/spidermonkey/fdlibm/e_gamma_r.c +70 -0
- data/vendor/spidermonkey/fdlibm/e_hypot.c +173 -0
- data/vendor/spidermonkey/fdlibm/e_j0.c +524 -0
- data/vendor/spidermonkey/fdlibm/e_j1.c +523 -0
- data/vendor/spidermonkey/fdlibm/e_jn.c +315 -0
- data/vendor/spidermonkey/fdlibm/e_lgamma.c +71 -0
- data/vendor/spidermonkey/fdlibm/e_lgamma_r.c +347 -0
- data/vendor/spidermonkey/fdlibm/e_log.c +184 -0
- data/vendor/spidermonkey/fdlibm/e_log10.c +134 -0
- data/vendor/spidermonkey/fdlibm/e_pow.c +386 -0
- data/vendor/spidermonkey/fdlibm/e_rem_pio2.c +222 -0
- data/vendor/spidermonkey/fdlibm/e_remainder.c +120 -0
- data/vendor/spidermonkey/fdlibm/e_scalb.c +89 -0
- data/vendor/spidermonkey/fdlibm/e_sinh.c +122 -0
- data/vendor/spidermonkey/fdlibm/e_sqrt.c +497 -0
- data/vendor/spidermonkey/fdlibm/fdlibm.h +273 -0
- data/vendor/spidermonkey/fdlibm/fdlibm.mak +1453 -0
- data/vendor/spidermonkey/fdlibm/fdlibm.mdp +0 -0
- data/vendor/spidermonkey/fdlibm/k_cos.c +135 -0
- data/vendor/spidermonkey/fdlibm/k_rem_pio2.c +354 -0
- data/vendor/spidermonkey/fdlibm/k_sin.c +114 -0
- data/vendor/spidermonkey/fdlibm/k_standard.c +785 -0
- data/vendor/spidermonkey/fdlibm/k_tan.c +170 -0
- data/vendor/spidermonkey/fdlibm/s_asinh.c +101 -0
- data/vendor/spidermonkey/fdlibm/s_atan.c +175 -0
- data/vendor/spidermonkey/fdlibm/s_cbrt.c +133 -0
- data/vendor/spidermonkey/fdlibm/s_ceil.c +120 -0
- data/vendor/spidermonkey/fdlibm/s_copysign.c +72 -0
- data/vendor/spidermonkey/fdlibm/s_cos.c +118 -0
- data/vendor/spidermonkey/fdlibm/s_erf.c +356 -0
- data/vendor/spidermonkey/fdlibm/s_expm1.c +267 -0
- data/vendor/spidermonkey/fdlibm/s_fabs.c +70 -0
- data/vendor/spidermonkey/fdlibm/s_finite.c +71 -0
- data/vendor/spidermonkey/fdlibm/s_floor.c +121 -0
- data/vendor/spidermonkey/fdlibm/s_frexp.c +99 -0
- data/vendor/spidermonkey/fdlibm/s_ilogb.c +85 -0
- data/vendor/spidermonkey/fdlibm/s_isnan.c +74 -0
- data/vendor/spidermonkey/fdlibm/s_ldexp.c +66 -0
- data/vendor/spidermonkey/fdlibm/s_lib_version.c +73 -0
- data/vendor/spidermonkey/fdlibm/s_log1p.c +211 -0
- data/vendor/spidermonkey/fdlibm/s_logb.c +79 -0
- data/vendor/spidermonkey/fdlibm/s_matherr.c +64 -0
- data/vendor/spidermonkey/fdlibm/s_modf.c +132 -0
- data/vendor/spidermonkey/fdlibm/s_nextafter.c +124 -0
- data/vendor/spidermonkey/fdlibm/s_rint.c +131 -0
- data/vendor/spidermonkey/fdlibm/s_scalbn.c +107 -0
- data/vendor/spidermonkey/fdlibm/s_signgam.c +40 -0
- data/vendor/spidermonkey/fdlibm/s_significand.c +68 -0
- data/vendor/spidermonkey/fdlibm/s_sin.c +118 -0
- data/vendor/spidermonkey/fdlibm/s_tan.c +112 -0
- data/vendor/spidermonkey/fdlibm/s_tanh.c +122 -0
- data/vendor/spidermonkey/fdlibm/w_acos.c +78 -0
- data/vendor/spidermonkey/fdlibm/w_acosh.c +78 -0
- data/vendor/spidermonkey/fdlibm/w_asin.c +80 -0
- data/vendor/spidermonkey/fdlibm/w_atan2.c +79 -0
- data/vendor/spidermonkey/fdlibm/w_atanh.c +81 -0
- data/vendor/spidermonkey/fdlibm/w_cosh.c +77 -0
- data/vendor/spidermonkey/fdlibm/w_exp.c +88 -0
- data/vendor/spidermonkey/fdlibm/w_fmod.c +78 -0
- data/vendor/spidermonkey/fdlibm/w_gamma.c +85 -0
- data/vendor/spidermonkey/fdlibm/w_gamma_r.c +81 -0
- data/vendor/spidermonkey/fdlibm/w_hypot.c +78 -0
- data/vendor/spidermonkey/fdlibm/w_j0.c +105 -0
- data/vendor/spidermonkey/fdlibm/w_j1.c +106 -0
- data/vendor/spidermonkey/fdlibm/w_jn.c +128 -0
- data/vendor/spidermonkey/fdlibm/w_lgamma.c +85 -0
- data/vendor/spidermonkey/fdlibm/w_lgamma_r.c +81 -0
- data/vendor/spidermonkey/fdlibm/w_log.c +78 -0
- data/vendor/spidermonkey/fdlibm/w_log10.c +81 -0
- data/vendor/spidermonkey/fdlibm/w_pow.c +99 -0
- data/vendor/spidermonkey/fdlibm/w_remainder.c +77 -0
- data/vendor/spidermonkey/fdlibm/w_scalb.c +95 -0
- data/vendor/spidermonkey/fdlibm/w_sinh.c +77 -0
- data/vendor/spidermonkey/fdlibm/w_sqrt.c +77 -0
- data/vendor/spidermonkey/javascript-trace.d +73 -0
- data/vendor/spidermonkey/js.c +3951 -0
- data/vendor/spidermonkey/js.mdp +0 -0
- data/vendor/spidermonkey/js.msg +308 -0
- data/vendor/spidermonkey/js.pkg +2 -0
- data/vendor/spidermonkey/js3240.rc +79 -0
- data/vendor/spidermonkey/jsOS240.def +654 -0
- data/vendor/spidermonkey/jsapi.c +5836 -0
- data/vendor/spidermonkey/jsapi.h +2624 -0
- data/vendor/spidermonkey/jsarena.c +450 -0
- data/vendor/spidermonkey/jsarena.h +318 -0
- data/vendor/spidermonkey/jsarray.c +2996 -0
- data/vendor/spidermonkey/jsarray.h +127 -0
- data/vendor/spidermonkey/jsatom.c +1045 -0
- data/vendor/spidermonkey/jsatom.h +442 -0
- data/vendor/spidermonkey/jsbit.h +253 -0
- data/vendor/spidermonkey/jsbool.c +176 -0
- data/vendor/spidermonkey/jsbool.h +73 -0
- data/vendor/spidermonkey/jsclist.h +139 -0
- data/vendor/spidermonkey/jscntxt.c +1348 -0
- data/vendor/spidermonkey/jscntxt.h +1120 -0
- data/vendor/spidermonkey/jscompat.h +57 -0
- data/vendor/spidermonkey/jsconfig.h +248 -0
- data/vendor/spidermonkey/jsconfig.mk +181 -0
- data/vendor/spidermonkey/jscpucfg.c +396 -0
- data/vendor/spidermonkey/jscpucfg.h +212 -0
- data/vendor/spidermonkey/jsdate.c +2390 -0
- data/vendor/spidermonkey/jsdate.h +124 -0
- data/vendor/spidermonkey/jsdbgapi.c +1802 -0
- data/vendor/spidermonkey/jsdbgapi.h +464 -0
- data/vendor/spidermonkey/jsdhash.c +868 -0
- data/vendor/spidermonkey/jsdhash.h +592 -0
- data/vendor/spidermonkey/jsdtoa.c +3167 -0
- data/vendor/spidermonkey/jsdtoa.h +130 -0
- data/vendor/spidermonkey/jsdtracef.c +317 -0
- data/vendor/spidermonkey/jsdtracef.h +77 -0
- data/vendor/spidermonkey/jsemit.c +6909 -0
- data/vendor/spidermonkey/jsemit.h +741 -0
- data/vendor/spidermonkey/jsexn.c +1371 -0
- data/vendor/spidermonkey/jsexn.h +96 -0
- data/vendor/spidermonkey/jsfile.c +2736 -0
- data/vendor/spidermonkey/jsfile.h +56 -0
- data/vendor/spidermonkey/jsfile.msg +90 -0
- data/vendor/spidermonkey/jsfun.c +2634 -0
- data/vendor/spidermonkey/jsfun.h +254 -0
- data/vendor/spidermonkey/jsgc.c +3562 -0
- data/vendor/spidermonkey/jsgc.h +403 -0
- data/vendor/spidermonkey/jshash.c +476 -0
- data/vendor/spidermonkey/jshash.h +151 -0
- data/vendor/spidermonkey/jsify.pl +485 -0
- data/vendor/spidermonkey/jsinterp.c +7007 -0
- data/vendor/spidermonkey/jsinterp.h +525 -0
- data/vendor/spidermonkey/jsinvoke.c +43 -0
- data/vendor/spidermonkey/jsiter.c +1067 -0
- data/vendor/spidermonkey/jsiter.h +122 -0
- data/vendor/spidermonkey/jskeyword.tbl +124 -0
- data/vendor/spidermonkey/jskwgen.c +460 -0
- data/vendor/spidermonkey/jslibmath.h +266 -0
- data/vendor/spidermonkey/jslock.c +1309 -0
- data/vendor/spidermonkey/jslock.h +313 -0
- data/vendor/spidermonkey/jslocko.asm +60 -0
- data/vendor/spidermonkey/jslog2.c +94 -0
- data/vendor/spidermonkey/jslong.c +264 -0
- data/vendor/spidermonkey/jslong.h +412 -0
- data/vendor/spidermonkey/jsmath.c +567 -0
- data/vendor/spidermonkey/jsmath.h +57 -0
- data/vendor/spidermonkey/jsnum.c +1239 -0
- data/vendor/spidermonkey/jsnum.h +283 -0
- data/vendor/spidermonkey/jsobj.c +5282 -0
- data/vendor/spidermonkey/jsobj.h +709 -0
- data/vendor/spidermonkey/jsopcode.c +5245 -0
- data/vendor/spidermonkey/jsopcode.h +394 -0
- data/vendor/spidermonkey/jsopcode.tbl +523 -0
- data/vendor/spidermonkey/jsotypes.h +202 -0
- data/vendor/spidermonkey/jsparse.c +6704 -0
- data/vendor/spidermonkey/jsparse.h +511 -0
- data/vendor/spidermonkey/jsprf.c +1264 -0
- data/vendor/spidermonkey/jsprf.h +150 -0
- data/vendor/spidermonkey/jsproto.tbl +128 -0
- data/vendor/spidermonkey/jsprvtd.h +267 -0
- data/vendor/spidermonkey/jspubtd.h +744 -0
- data/vendor/spidermonkey/jsregexp.c +4364 -0
- data/vendor/spidermonkey/jsregexp.h +183 -0
- data/vendor/spidermonkey/jsreops.tbl +145 -0
- data/vendor/spidermonkey/jsscan.c +2012 -0
- data/vendor/spidermonkey/jsscan.h +387 -0
- data/vendor/spidermonkey/jsscope.c +1957 -0
- data/vendor/spidermonkey/jsscope.h +418 -0
- data/vendor/spidermonkey/jsscript.c +1832 -0
- data/vendor/spidermonkey/jsscript.h +287 -0
- data/vendor/spidermonkey/jsshell.msg +50 -0
- data/vendor/spidermonkey/jsstddef.h +83 -0
- data/vendor/spidermonkey/jsstr.c +5005 -0
- data/vendor/spidermonkey/jsstr.h +641 -0
- data/vendor/spidermonkey/jstypes.h +475 -0
- data/vendor/spidermonkey/jsutil.c +345 -0
- data/vendor/spidermonkey/jsutil.h +157 -0
- data/vendor/spidermonkey/jsxdrapi.c +800 -0
- data/vendor/spidermonkey/jsxdrapi.h +218 -0
- data/vendor/spidermonkey/jsxml.c +8476 -0
- data/vendor/spidermonkey/jsxml.h +349 -0
- data/vendor/spidermonkey/lock_SunOS.s +119 -0
- data/vendor/spidermonkey/perfect.js +39 -0
- data/vendor/spidermonkey/plify_jsdhash.sed +36 -0
- data/vendor/spidermonkey/prmjtime.c +846 -0
- data/vendor/spidermonkey/prmjtime.h +103 -0
- data/vendor/spidermonkey/resource.h +15 -0
- data/vendor/spidermonkey/rules.mk +197 -0
- data/vendor/spidermonkey/win32.order +384 -0
- data/vendor/tracemonkey/Makefile.in +668 -0
- data/vendor/tracemonkey/Makefile.ref +483 -0
- data/vendor/tracemonkey/README.html +54 -0
- data/vendor/tracemonkey/SpiderMonkey.rsp +11 -0
- data/vendor/tracemonkey/Y.js +19 -0
- data/vendor/tracemonkey/aclocal.m4 +9 -0
- data/vendor/tracemonkey/bench.sh +5 -0
- data/vendor/tracemonkey/build/autoconf/acoutput-fast.pl +202 -0
- data/vendor/tracemonkey/build/autoconf/altoptions.m4 +154 -0
- data/vendor/tracemonkey/build/autoconf/config.guess +1537 -0
- data/vendor/tracemonkey/build/autoconf/config.sub +1595 -0
- data/vendor/tracemonkey/build/autoconf/install-sh +119 -0
- data/vendor/tracemonkey/build/autoconf/make-makefile +315 -0
- data/vendor/tracemonkey/build/autoconf/match-dir.sh +101 -0
- data/vendor/tracemonkey/build/autoconf/moznbytetype.m4 +136 -0
- data/vendor/tracemonkey/build/autoconf/nspr.m4 +82 -0
- data/vendor/tracemonkey/build/autoconf/pkg.m4 +59 -0
- data/vendor/tracemonkey/build/autoconf/update-makefile.sh +118 -0
- data/vendor/tracemonkey/build/cygwin-wrapper +75 -0
- data/vendor/tracemonkey/build/hcc +111 -0
- data/vendor/tracemonkey/build/hcpp +155 -0
- data/vendor/tracemonkey/build/unix/mddepend.pl +165 -0
- data/vendor/tracemonkey/build/unix/uniq.pl +63 -0
- data/vendor/tracemonkey/build/win32/pgomerge.py +40 -0
- data/vendor/tracemonkey/builtins.tbl +91 -0
- data/vendor/tracemonkey/call.js +13 -0
- data/vendor/tracemonkey/config/Makefile.in +106 -0
- data/vendor/tracemonkey/config/Moz/Milestone.pm +232 -0
- data/vendor/tracemonkey/config/autoconf.mk.in +362 -0
- data/vendor/tracemonkey/config/check-sync-dirs.py +103 -0
- data/vendor/tracemonkey/config/check-sync-exceptions +7 -0
- data/vendor/tracemonkey/config/config.mk +881 -0
- data/vendor/tracemonkey/config/fastcwd.pl +66 -0
- data/vendor/tracemonkey/config/gcc_hidden.h +2 -0
- data/vendor/tracemonkey/config/insure.mk +53 -0
- data/vendor/tracemonkey/config/make-system-wrappers.pl +59 -0
- data/vendor/tracemonkey/config/milestone.pl +112 -0
- data/vendor/tracemonkey/config/milestone.txt +13 -0
- data/vendor/tracemonkey/config/mkdepend/Makefile.in +84 -0
- data/vendor/tracemonkey/config/mkdepend/cppsetup.c +233 -0
- data/vendor/tracemonkey/config/mkdepend/def.h +184 -0
- data/vendor/tracemonkey/config/mkdepend/ifparser.c +551 -0
- data/vendor/tracemonkey/config/mkdepend/ifparser.h +83 -0
- data/vendor/tracemonkey/config/mkdepend/imakemdep.h +733 -0
- data/vendor/tracemonkey/config/mkdepend/include.c +337 -0
- data/vendor/tracemonkey/config/mkdepend/main.c +860 -0
- data/vendor/tracemonkey/config/mkdepend/mkdepend.man +382 -0
- data/vendor/tracemonkey/config/mkdepend/parse.c +686 -0
- data/vendor/tracemonkey/config/mkdepend/pr.c +124 -0
- data/vendor/tracemonkey/config/nfspwd.pl +50 -0
- data/vendor/tracemonkey/config/nsinstall.c +481 -0
- data/vendor/tracemonkey/config/nsinstall.py +155 -0
- data/vendor/tracemonkey/config/pathsub.c +247 -0
- data/vendor/tracemonkey/config/pathsub.h +74 -0
- data/vendor/tracemonkey/config/preprocessor.pl +671 -0
- data/vendor/tracemonkey/config/revdepth-nt.pl +48 -0
- data/vendor/tracemonkey/config/revdepth.pl +51 -0
- data/vendor/tracemonkey/config/rules.mk +2310 -0
- data/vendor/tracemonkey/config/static-checking-config.mk +21 -0
- data/vendor/tracemonkey/config/static-checking.js +92 -0
- data/vendor/tracemonkey/config/string-format.js +61 -0
- data/vendor/tracemonkey/config/system-headers +1035 -0
- data/vendor/tracemonkey/config/version.mk +85 -0
- data/vendor/tracemonkey/config/version_win.pl +442 -0
- data/vendor/tracemonkey/config.mk +206 -0
- data/vendor/tracemonkey/configure +14183 -0
- data/vendor/tracemonkey/configure.in +5363 -0
- data/vendor/tracemonkey/correct/check-3d-morph.js +55 -0
- data/vendor/tracemonkey/correct/check-3d-raytrace.js +445 -0
- data/vendor/tracemonkey/correct/check-access-binary-trees.js +52 -0
- data/vendor/tracemonkey/correct/check-access-fannkuch.js +66 -0
- data/vendor/tracemonkey/correct/check-access-nbody.js +171 -0
- data/vendor/tracemonkey/correct/check-access-nsieve.js +40 -0
- data/vendor/tracemonkey/correct/check-bitops-3bit-bits-in-byte.js +35 -0
- data/vendor/tracemonkey/correct/check-bitops-bits-in-byte.js +24 -0
- data/vendor/tracemonkey/correct/check-bitops-bitwise-and.js +29 -0
- data/vendor/tracemonkey/correct/check-bitops-nsieve-bits.js +40 -0
- data/vendor/tracemonkey/correct/check-controlflow-recursive.js +27 -0
- data/vendor/tracemonkey/correct/check-date-format-tofte.js +302 -0
- data/vendor/tracemonkey/correct/check-date-format-xparb.js +421 -0
- data/vendor/tracemonkey/correct/check-mont.js +119 -0
- data/vendor/tracemonkey/correct.sh +23 -0
- data/vendor/tracemonkey/dtoa.c +3335 -0
- data/vendor/tracemonkey/editline/Makefile.in +55 -0
- data/vendor/tracemonkey/editline/Makefile.ref +143 -0
- data/vendor/tracemonkey/editline/README +83 -0
- data/vendor/tracemonkey/editline/editline.3 +175 -0
- data/vendor/tracemonkey/editline/editline.c +1371 -0
- data/vendor/tracemonkey/editline/editline.h +135 -0
- data/vendor/tracemonkey/editline/sysunix.c +182 -0
- data/vendor/tracemonkey/editline/unix.h +82 -0
- data/vendor/tracemonkey/if.js +13 -0
- data/vendor/tracemonkey/imacro_asm.js.in +396 -0
- data/vendor/tracemonkey/imacros.c.out +1034 -0
- data/vendor/tracemonkey/imacros.jsasm +770 -0
- data/vendor/tracemonkey/javascript-trace.d +73 -0
- data/vendor/tracemonkey/jitstats.tbl +55 -0
- data/vendor/tracemonkey/js-config.h.in +82 -0
- data/vendor/tracemonkey/js-config.in +111 -0
- data/vendor/tracemonkey/js.mdp +0 -0
- data/vendor/tracemonkey/js.msg +312 -0
- data/vendor/tracemonkey/js3240.rc +79 -0
- data/vendor/tracemonkey/jsOS240.def +654 -0
- data/vendor/tracemonkey/jsapi.cpp +6005 -0
- data/vendor/tracemonkey/jsapi.h +2727 -0
- data/vendor/tracemonkey/jsarena.cpp +450 -0
- data/vendor/tracemonkey/jsarena.h +318 -0
- data/vendor/tracemonkey/jsarray.cpp +3664 -0
- data/vendor/tracemonkey/jsarray.h +238 -0
- data/vendor/tracemonkey/jsatom.cpp +1244 -0
- data/vendor/tracemonkey/jsatom.h +493 -0
- data/vendor/tracemonkey/jsbit.h +249 -0
- data/vendor/tracemonkey/jsbool.cpp +184 -0
- data/vendor/tracemonkey/jsbool.h +88 -0
- data/vendor/tracemonkey/jsbuiltins.cpp +415 -0
- data/vendor/tracemonkey/jsbuiltins.h +456 -0
- data/vendor/tracemonkey/jsclist.h +139 -0
- data/vendor/tracemonkey/jscntxt.cpp +1816 -0
- data/vendor/tracemonkey/jscntxt.h +1541 -0
- data/vendor/tracemonkey/jscompat.h +57 -0
- data/vendor/tracemonkey/jsconfig.mk +181 -0
- data/vendor/tracemonkey/jscpucfg.cpp +194 -0
- data/vendor/tracemonkey/jscpucfg.h +91 -0
- data/vendor/tracemonkey/jsdate.cpp +2465 -0
- data/vendor/tracemonkey/jsdate.h +129 -0
- data/vendor/tracemonkey/jsdbgapi.cpp +2017 -0
- data/vendor/tracemonkey/jsdbgapi.h +500 -0
- data/vendor/tracemonkey/jsdhash.cpp +876 -0
- data/vendor/tracemonkey/jsdhash.h +588 -0
- data/vendor/tracemonkey/jsdtoa.cpp +572 -0
- data/vendor/tracemonkey/jsdtoa.h +131 -0
- data/vendor/tracemonkey/jsdtracef.c +318 -0
- data/vendor/tracemonkey/jsdtracef.h +81 -0
- data/vendor/tracemonkey/jsemit.cpp +7292 -0
- data/vendor/tracemonkey/jsemit.h +802 -0
- data/vendor/tracemonkey/jsexn.cpp +1337 -0
- data/vendor/tracemonkey/jsexn.h +96 -0
- data/vendor/tracemonkey/jsfile.cpp +2747 -0
- data/vendor/tracemonkey/jsfile.h +56 -0
- data/vendor/tracemonkey/jsfile.msg +90 -0
- data/vendor/tracemonkey/jsfun.cpp +3089 -0
- data/vendor/tracemonkey/jsfun.h +366 -0
- data/vendor/tracemonkey/jsgc.cpp +3816 -0
- data/vendor/tracemonkey/jsgc.h +429 -0
- data/vendor/tracemonkey/jshash.cpp +477 -0
- data/vendor/tracemonkey/jshash.h +151 -0
- data/vendor/tracemonkey/jsify.pl +483 -0
- data/vendor/tracemonkey/jsinterp.cpp +7441 -0
- data/vendor/tracemonkey/jsinterp.h +666 -0
- data/vendor/tracemonkey/jsinvoke.cpp +42 -0
- data/vendor/tracemonkey/jsiter.cpp +1040 -0
- data/vendor/tracemonkey/jsiter.h +140 -0
- data/vendor/tracemonkey/jskeyword.tbl +124 -0
- data/vendor/tracemonkey/jskwgen.cpp +460 -0
- data/vendor/tracemonkey/jslibmath.h +69 -0
- data/vendor/tracemonkey/jslock.cpp +1512 -0
- data/vendor/tracemonkey/jslock.h +325 -0
- data/vendor/tracemonkey/jslocko.asm +60 -0
- data/vendor/tracemonkey/jslog2.cpp +111 -0
- data/vendor/tracemonkey/jslong.h +167 -0
- data/vendor/tracemonkey/jsmath.cpp +806 -0
- data/vendor/tracemonkey/jsmath.h +63 -0
- data/vendor/tracemonkey/jsnum.cpp +1374 -0
- data/vendor/tracemonkey/jsnum.h +280 -0
- data/vendor/tracemonkey/jsobj.cpp +6165 -0
- data/vendor/tracemonkey/jsobj.h +873 -0
- data/vendor/tracemonkey/json.cpp +1338 -0
- data/vendor/tracemonkey/json.h +108 -0
- data/vendor/tracemonkey/jsopcode.cpp +5484 -0
- data/vendor/tracemonkey/jsopcode.h +434 -0
- data/vendor/tracemonkey/jsopcode.tbl +591 -0
- data/vendor/tracemonkey/jsoplengen.cpp +121 -0
- data/vendor/tracemonkey/jsotypes.h +202 -0
- data/vendor/tracemonkey/jsparse.cpp +9272 -0
- data/vendor/tracemonkey/jsparse.h +900 -0
- data/vendor/tracemonkey/jsprf.cpp +1262 -0
- data/vendor/tracemonkey/jsprf.h +150 -0
- data/vendor/tracemonkey/jsproto.tbl +117 -0
- data/vendor/tracemonkey/jsprvtd.h +366 -0
- data/vendor/tracemonkey/jspubtd.h +585 -0
- data/vendor/tracemonkey/jsregexp.cpp +5051 -0
- data/vendor/tracemonkey/jsregexp.h +199 -0
- data/vendor/tracemonkey/jsreops.tbl +145 -0
- data/vendor/tracemonkey/jsscan.cpp +2040 -0
- data/vendor/tracemonkey/jsscan.h +467 -0
- data/vendor/tracemonkey/jsscope.cpp +1966 -0
- data/vendor/tracemonkey/jsscope.h +487 -0
- data/vendor/tracemonkey/jsscript.cpp +1932 -0
- data/vendor/tracemonkey/jsscript.h +345 -0
- data/vendor/tracemonkey/jsshell.msg +54 -0
- data/vendor/tracemonkey/jsstack.js +167 -0
- data/vendor/tracemonkey/jsstaticcheck.h +69 -0
- data/vendor/tracemonkey/jsstddef.h +87 -0
- data/vendor/tracemonkey/jsstdint.h +96 -0
- data/vendor/tracemonkey/jsstr.cpp +5277 -0
- data/vendor/tracemonkey/jsstr.h +702 -0
- data/vendor/tracemonkey/jstracer.cpp +10991 -0
- data/vendor/tracemonkey/jstracer.h +794 -0
- data/vendor/tracemonkey/jstypes.h +481 -0
- data/vendor/tracemonkey/jsutil.cpp +361 -0
- data/vendor/tracemonkey/jsutil.h +178 -0
- data/vendor/tracemonkey/jsversion.h +243 -0
- data/vendor/tracemonkey/jswince.asm +44 -0
- data/vendor/tracemonkey/jsxdrapi.cpp +800 -0
- data/vendor/tracemonkey/jsxdrapi.h +220 -0
- data/vendor/tracemonkey/jsxml.cpp +8327 -0
- data/vendor/tracemonkey/jsxml.h +305 -0
- data/vendor/tracemonkey/liveconnect/LiveConnect.dsp +157 -0
- data/vendor/tracemonkey/liveconnect/LiveConnectShell.dsp +120 -0
- data/vendor/tracemonkey/liveconnect/LiveConnectShell.dsw +44 -0
- data/vendor/tracemonkey/liveconnect/Makefile.in +105 -0
- data/vendor/tracemonkey/liveconnect/Makefile.ref +169 -0
- data/vendor/tracemonkey/liveconnect/README.html +712 -0
- data/vendor/tracemonkey/liveconnect/_jni/netscape_javascript_JSException.h +14 -0
- data/vendor/tracemonkey/liveconnect/_jni/netscape_javascript_JSObject.h +155 -0
- data/vendor/tracemonkey/liveconnect/classes/Makefile.in +89 -0
- data/vendor/tracemonkey/liveconnect/classes/Makefile.ref +57 -0
- data/vendor/tracemonkey/liveconnect/classes/netscape/Makefile.ref +47 -0
- data/vendor/tracemonkey/liveconnect/classes/netscape/javascript/JSException.java +140 -0
- data/vendor/tracemonkey/liveconnect/classes/netscape/javascript/JSObject.java +183 -0
- data/vendor/tracemonkey/liveconnect/classes/netscape/javascript/JSProxy.java +58 -0
- data/vendor/tracemonkey/liveconnect/classes/netscape/javascript/JSRunnable.java +70 -0
- data/vendor/tracemonkey/liveconnect/classes/netscape/javascript/JSUtil.java +59 -0
- data/vendor/tracemonkey/liveconnect/classes/netscape/javascript/Makefile.ref +53 -0
- data/vendor/tracemonkey/liveconnect/config/AIX4.1.mk +45 -0
- data/vendor/tracemonkey/liveconnect/config/AIX4.2.mk +45 -0
- data/vendor/tracemonkey/liveconnect/config/AIX4.3.mk +50 -0
- data/vendor/tracemonkey/liveconnect/config/HP-UXB.10.10.mk +43 -0
- data/vendor/tracemonkey/liveconnect/config/HP-UXB.10.20.mk +43 -0
- data/vendor/tracemonkey/liveconnect/config/HP-UXB.11.00.mk +43 -0
- data/vendor/tracemonkey/liveconnect/config/IRIX6.2.mk +43 -0
- data/vendor/tracemonkey/liveconnect/config/IRIX6.3.mk +43 -0
- data/vendor/tracemonkey/liveconnect/config/IRIX6.5.mk +43 -0
- data/vendor/tracemonkey/liveconnect/config/Linux_All.mk +73 -0
- data/vendor/tracemonkey/liveconnect/config/OSF1V4.0.mk +65 -0
- data/vendor/tracemonkey/liveconnect/config/OSF1V5.0.mk +62 -0
- data/vendor/tracemonkey/liveconnect/config/SunOS5.5.1.mk +55 -0
- data/vendor/tracemonkey/liveconnect/config/SunOS5.6.mk +39 -0
- data/vendor/tracemonkey/liveconnect/config/SunOS5.7.mk +39 -0
- data/vendor/tracemonkey/liveconnect/config/SunOS5.8.mk +39 -0
- data/vendor/tracemonkey/liveconnect/config/WINNT4.0.mk +53 -0
- data/vendor/tracemonkey/liveconnect/jsj.c +886 -0
- data/vendor/tracemonkey/liveconnect/jsj.msg +98 -0
- data/vendor/tracemonkey/liveconnect/jsj_JSObject.c +1377 -0
- data/vendor/tracemonkey/liveconnect/jsj_JavaArray.c +474 -0
- data/vendor/tracemonkey/liveconnect/jsj_JavaClass.c +737 -0
- data/vendor/tracemonkey/liveconnect/jsj_JavaMember.c +191 -0
- data/vendor/tracemonkey/liveconnect/jsj_JavaObject.c +1079 -0
- data/vendor/tracemonkey/liveconnect/jsj_JavaPackage.c +569 -0
- data/vendor/tracemonkey/liveconnect/jsj_array.c +207 -0
- data/vendor/tracemonkey/liveconnect/jsj_class.c +770 -0
- data/vendor/tracemonkey/liveconnect/jsj_convert.c +902 -0
- data/vendor/tracemonkey/liveconnect/jsj_field.c +421 -0
- data/vendor/tracemonkey/liveconnect/jsj_hash.c +488 -0
- data/vendor/tracemonkey/liveconnect/jsj_hash.h +161 -0
- data/vendor/tracemonkey/liveconnect/jsj_method.c +1825 -0
- data/vendor/tracemonkey/liveconnect/jsj_nodl.c +1 -0
- data/vendor/tracemonkey/liveconnect/jsj_private.h +677 -0
- data/vendor/tracemonkey/liveconnect/jsj_simpleapi.c +219 -0
- data/vendor/tracemonkey/liveconnect/jsj_utils.c +513 -0
- data/vendor/tracemonkey/liveconnect/jsjava.h +316 -0
- data/vendor/tracemonkey/liveconnect/netscape_javascript_JSObject.h +155 -0
- data/vendor/tracemonkey/liveconnect/nsCLiveconnect.cpp +785 -0
- data/vendor/tracemonkey/liveconnect/nsCLiveconnect.h +197 -0
- data/vendor/tracemonkey/liveconnect/nsCLiveconnectFactory.cpp +118 -0
- data/vendor/tracemonkey/liveconnect/nsCLiveconnectFactory.h +76 -0
- data/vendor/tracemonkey/liveconnect/nsILiveconnect.h +197 -0
- data/vendor/tracemonkey/liveconnect/nsISecureLiveconnect.h +94 -0
- data/vendor/tracemonkey/liveconnect/nsISecurityContext.h +136 -0
- data/vendor/tracemonkey/lock_SunOS.s +119 -0
- data/vendor/tracemonkey/mandelbrot-results.js +3 -0
- data/vendor/tracemonkey/math-partial-sums.js +32 -0
- data/vendor/tracemonkey/math-trace-tests.js +507 -0
- data/vendor/tracemonkey/md5.js +289 -0
- data/vendor/tracemonkey/nanojit/Assembler.cpp +1984 -0
- data/vendor/tracemonkey/nanojit/Assembler.h +375 -0
- data/vendor/tracemonkey/nanojit/Fragmento.cpp +651 -0
- data/vendor/tracemonkey/nanojit/Fragmento.h +237 -0
- data/vendor/tracemonkey/nanojit/LIR.cpp +2314 -0
- data/vendor/tracemonkey/nanojit/LIR.h +879 -0
- data/vendor/tracemonkey/nanojit/LIRopcode.tbl +252 -0
- data/vendor/tracemonkey/nanojit/Native.h +127 -0
- data/vendor/tracemonkey/nanojit/NativeARM.cpp +1742 -0
- data/vendor/tracemonkey/nanojit/NativeARM.h +844 -0
- data/vendor/tracemonkey/nanojit/NativeSparc.cpp +1130 -0
- data/vendor/tracemonkey/nanojit/NativeSparc.h +948 -0
- data/vendor/tracemonkey/nanojit/NativeThumb.cpp +1322 -0
- data/vendor/tracemonkey/nanojit/NativeThumb.h +525 -0
- data/vendor/tracemonkey/nanojit/Nativei386.cpp +1748 -0
- data/vendor/tracemonkey/nanojit/Nativei386.h +857 -0
- data/vendor/tracemonkey/nanojit/RegAlloc.cpp +183 -0
- data/vendor/tracemonkey/nanojit/RegAlloc.h +95 -0
- data/vendor/tracemonkey/nanojit/TraceTreeDrawer.cpp +306 -0
- data/vendor/tracemonkey/nanojit/TraceTreeDrawer.h +88 -0
- data/vendor/tracemonkey/nanojit/avmplus.cpp +56 -0
- data/vendor/tracemonkey/nanojit/avmplus.h +1016 -0
- data/vendor/tracemonkey/nanojit/nanojit.h +253 -0
- data/vendor/tracemonkey/perfect.js +39 -0
- data/vendor/tracemonkey/plify_jsdhash.sed +35 -0
- data/vendor/tracemonkey/prmjtime.cpp +869 -0
- data/vendor/tracemonkey/prmjtime.h +103 -0
- data/vendor/tracemonkey/ref-config/AIX4.1.mk +65 -0
- data/vendor/tracemonkey/ref-config/AIX4.2.mk +64 -0
- data/vendor/tracemonkey/ref-config/AIX4.3.mk +65 -0
- data/vendor/tracemonkey/ref-config/Darwin.mk +85 -0
- data/vendor/tracemonkey/ref-config/Darwin1.3.mk +81 -0
- data/vendor/tracemonkey/ref-config/Darwin1.4.mk +41 -0
- data/vendor/tracemonkey/ref-config/Darwin5.2.mk +81 -0
- data/vendor/tracemonkey/ref-config/Darwin5.3.mk +81 -0
- data/vendor/tracemonkey/ref-config/Darwin64.mk +72 -0
- data/vendor/tracemonkey/ref-config/HP-UXB.10.10.mk +77 -0
- data/vendor/tracemonkey/ref-config/HP-UXB.10.20.mk +77 -0
- data/vendor/tracemonkey/ref-config/HP-UXB.11.00.mk +80 -0
- data/vendor/tracemonkey/ref-config/IRIX.mk +87 -0
- data/vendor/tracemonkey/ref-config/IRIX5.3.mk +44 -0
- data/vendor/tracemonkey/ref-config/IRIX6.1.mk +44 -0
- data/vendor/tracemonkey/ref-config/IRIX6.2.mk +44 -0
- data/vendor/tracemonkey/ref-config/IRIX6.3.mk +44 -0
- data/vendor/tracemonkey/ref-config/IRIX6.5.mk +44 -0
- data/vendor/tracemonkey/ref-config/Linux_All.mk +105 -0
- data/vendor/tracemonkey/ref-config/Mac_OS10.0.mk +82 -0
- data/vendor/tracemonkey/ref-config/OSF1V4.0.mk +72 -0
- data/vendor/tracemonkey/ref-config/OSF1V5.0.mk +69 -0
- data/vendor/tracemonkey/ref-config/SunOS4.1.4.mk +101 -0
- data/vendor/tracemonkey/ref-config/SunOS5.10.mk +50 -0
- data/vendor/tracemonkey/ref-config/SunOS5.3.mk +91 -0
- data/vendor/tracemonkey/ref-config/SunOS5.4.mk +92 -0
- data/vendor/tracemonkey/ref-config/SunOS5.5.1.mk +44 -0
- data/vendor/tracemonkey/ref-config/SunOS5.5.mk +87 -0
- data/vendor/tracemonkey/ref-config/SunOS5.6.mk +89 -0
- data/vendor/tracemonkey/ref-config/SunOS5.7.mk +44 -0
- data/vendor/tracemonkey/ref-config/SunOS5.8.mk +44 -0
- data/vendor/tracemonkey/ref-config/SunOS5.9.mk +44 -0
- data/vendor/tracemonkey/ref-config/WINNT4.0.mk +118 -0
- data/vendor/tracemonkey/ref-config/WINNT5.0.mk +118 -0
- data/vendor/tracemonkey/ref-config/WINNT5.1.mk +118 -0
- data/vendor/tracemonkey/ref-config/WINNT5.2.mk +118 -0
- data/vendor/tracemonkey/ref-config/WINNT6.0.mk +118 -0
- data/vendor/tracemonkey/ref-config/dgux.mk +64 -0
- data/vendor/tracemonkey/resource.h +15 -0
- data/vendor/tracemonkey/rules.mk +206 -0
- data/vendor/tracemonkey/shell/Makefile.in +72 -0
- data/vendor/tracemonkey/shell/js.cpp +4719 -0
- data/vendor/tracemonkey/t/3d-cube.js +337 -0
- data/vendor/tracemonkey/t/3d-morph.js +54 -0
- data/vendor/tracemonkey/t/3d-raytrace.js +441 -0
- data/vendor/tracemonkey/t/access-binary-trees.js +50 -0
- data/vendor/tracemonkey/t/access-fannkuch.js +66 -0
- data/vendor/tracemonkey/t/access-nbody.js +169 -0
- data/vendor/tracemonkey/t/access-nsieve.js +38 -0
- data/vendor/tracemonkey/t/bitops-3bit-bits-in-byte.js +32 -0
- data/vendor/tracemonkey/t/bitops-bits-in-byte.js +21 -0
- data/vendor/tracemonkey/t/bitops-bitwise-and.js +28 -0
- data/vendor/tracemonkey/t/bitops-nsieve-bits.js +32 -0
- data/vendor/tracemonkey/t/controlflow-recursive.js +25 -0
- data/vendor/tracemonkey/t/crypto-aes.js +422 -0
- data/vendor/tracemonkey/t/crypto-md5.js +286 -0
- data/vendor/tracemonkey/t/crypto-sha1.js +224 -0
- data/vendor/tracemonkey/t/date-format-tofte.js +299 -0
- data/vendor/tracemonkey/t/date-format-xparb.js +417 -0
- data/vendor/tracemonkey/t/math-cordic.js +95 -0
- data/vendor/tracemonkey/t/math-partial-sums.js +33 -0
- data/vendor/tracemonkey/t/math-spectral-norm.js +51 -0
- data/vendor/tracemonkey/t/regexp-dna.js +1712 -0
- data/vendor/tracemonkey/t/string-base64.js +135 -0
- data/vendor/tracemonkey/t/string-fasta.js +85 -0
- data/vendor/tracemonkey/t/string-tagcloud.js +265 -0
- data/vendor/tracemonkey/t/string-unpack-code.js +68 -0
- data/vendor/tracemonkey/t/string-validate-input.js +89 -0
- data/vendor/tracemonkey/time.sh +13 -0
- data/vendor/tracemonkey/trace-test.js +5564 -0
- data/vendor/tracemonkey/v8/base.js +187 -0
- data/vendor/tracemonkey/v8/crypto.js +1689 -0
- data/vendor/tracemonkey/v8/deltablue.js +880 -0
- data/vendor/tracemonkey/v8/earley-boyer.js +4682 -0
- data/vendor/tracemonkey/v8/raytrace.js +3418 -0
- data/vendor/tracemonkey/v8/richards.js +539 -0
- data/vendor/tracemonkey/v8/run-crypto.js +44 -0
- data/vendor/tracemonkey/v8/run-deltablue.js +44 -0
- data/vendor/tracemonkey/v8/run-earley-boyer.js +44 -0
- data/vendor/tracemonkey/v8/run-raytrace.js +44 -0
- data/vendor/tracemonkey/v8/run-richards.js +44 -0
- data/vendor/tracemonkey/v8/run.js +49 -0
- data/vendor/tracemonkey/vprof/readme.txt +93 -0
- data/vendor/tracemonkey/vprof/vprof.cpp +360 -0
- data/vendor/tracemonkey/vprof/vprof.h +245 -0
- data/vendor/tracemonkey/xpconnect/Makefile.in +67 -0
- data/vendor/tracemonkey/xpconnect/crashtests/117307-1.html +20 -0
- data/vendor/tracemonkey/xpconnect/crashtests/193710.html +11 -0
- data/vendor/tracemonkey/xpconnect/crashtests/290162-1.html +5 -0
- data/vendor/tracemonkey/xpconnect/crashtests/326615-1.html +16 -0
- data/vendor/tracemonkey/xpconnect/crashtests/328553-1.html +13 -0
- data/vendor/tracemonkey/xpconnect/crashtests/346258-1.html +12 -0
- data/vendor/tracemonkey/xpconnect/crashtests/346512-1-frame1.xhtml +16 -0
- data/vendor/tracemonkey/xpconnect/crashtests/346512-1-frame2.xhtml +15 -0
- data/vendor/tracemonkey/xpconnect/crashtests/346512-1.xhtml +30 -0
- data/vendor/tracemonkey/xpconnect/crashtests/382133-1.html +3 -0
- data/vendor/tracemonkey/xpconnect/crashtests/386680-1.html +22 -0
- data/vendor/tracemonkey/xpconnect/crashtests/394810-1.html +4 -0
- data/vendor/tracemonkey/xpconnect/crashtests/400349-1.html +20 -0
- data/vendor/tracemonkey/xpconnect/crashtests/403356-1.html +13 -0
- data/vendor/tracemonkey/xpconnect/crashtests/418139-1.svg +22 -0
- data/vendor/tracemonkey/xpconnect/crashtests/420513-1.html +11 -0
- data/vendor/tracemonkey/xpconnect/crashtests/453935-1.html +37 -0
- data/vendor/tracemonkey/xpconnect/crashtests/462926.html +12 -0
- data/vendor/tracemonkey/xpconnect/crashtests/468552-1.html +18 -0
- data/vendor/tracemonkey/xpconnect/crashtests/471366-1.html +12 -0
- data/vendor/tracemonkey/xpconnect/crashtests/475185-1.html +13 -0
- data/vendor/tracemonkey/xpconnect/crashtests/475291-1.html +14 -0
- data/vendor/tracemonkey/xpconnect/crashtests/503286-1.html +23 -0
- data/vendor/tracemonkey/xpconnect/crashtests/crashtests.list +21 -0
- data/vendor/tracemonkey/xpconnect/idl/Makefile.in +78 -0
- data/vendor/tracemonkey/xpconnect/idl/XPCIDispatch.idl +51 -0
- data/vendor/tracemonkey/xpconnect/idl/mozIJSSubScriptLoader.idl +64 -0
- data/vendor/tracemonkey/xpconnect/idl/nsIActiveXSecurityPolicy.idl +67 -0
- data/vendor/tracemonkey/xpconnect/idl/nsIDispatchSupport.idl +119 -0
- data/vendor/tracemonkey/xpconnect/idl/nsIJSContextStack.idl +85 -0
- data/vendor/tracemonkey/xpconnect/idl/nsIJSRuntimeService.idl +51 -0
- data/vendor/tracemonkey/xpconnect/idl/nsIScriptError.idl +102 -0
- data/vendor/tracemonkey/xpconnect/idl/nsIScriptableInterfaces.idl +67 -0
- data/vendor/tracemonkey/xpconnect/idl/nsIXPCScriptNotify.idl +66 -0
- data/vendor/tracemonkey/xpconnect/idl/nsIXPCScriptable.idl +183 -0
- data/vendor/tracemonkey/xpconnect/idl/nsIXPCSecurityManager.idl +114 -0
- data/vendor/tracemonkey/xpconnect/idl/nsIXPConnect.idl +819 -0
- data/vendor/tracemonkey/xpconnect/idl/xpcIJSModuleLoader.idl +95 -0
- data/vendor/tracemonkey/xpconnect/idl/xpcIJSWeakReference.idl +49 -0
- data/vendor/tracemonkey/xpconnect/idl/xpccomponents.idl +254 -0
- data/vendor/tracemonkey/xpconnect/idl/xpcexception.idl +66 -0
- data/vendor/tracemonkey/xpconnect/idl/xpcjsid.idl +83 -0
- data/vendor/tracemonkey/xpconnect/loader/ISO8601DateUtils.jsm +176 -0
- data/vendor/tracemonkey/xpconnect/loader/Makefile.in +63 -0
- data/vendor/tracemonkey/xpconnect/loader/XPCOMUtils.jsm +267 -0
- data/vendor/tracemonkey/xpconnect/loader/mozJSComponentLoader.cpp +1717 -0
- data/vendor/tracemonkey/xpconnect/loader/mozJSComponentLoader.h +172 -0
- data/vendor/tracemonkey/xpconnect/loader/mozJSLoaderConstructors.h +101 -0
- data/vendor/tracemonkey/xpconnect/loader/mozJSSubScriptLoader.cpp +360 -0
- data/vendor/tracemonkey/xpconnect/loader/mozJSSubScriptLoader.h +66 -0
- data/vendor/tracemonkey/xpconnect/public/Makefile.in +54 -0
- data/vendor/tracemonkey/xpconnect/public/nsAXPCNativeCallContext.h +89 -0
- data/vendor/tracemonkey/xpconnect/public/nsAutoJSValHolder.h +168 -0
- data/vendor/tracemonkey/xpconnect/public/xpc_map_end.h +327 -0
- data/vendor/tracemonkey/xpconnect/sample/Makefile.in +71 -0
- data/vendor/tracemonkey/xpconnect/sample/README +39 -0
- data/vendor/tracemonkey/xpconnect/sample/xpcsample1.cpp +337 -0
- data/vendor/tracemonkey/xpconnect/sample/xpcsample1.idl +82 -0
- data/vendor/tracemonkey/xpconnect/sample/xpcsample1.js +21 -0
- data/vendor/tracemonkey/xpconnect/shell/Makefile.in +106 -0
- data/vendor/tracemonkey/xpconnect/shell/jsshell.msg +50 -0
- data/vendor/tracemonkey/xpconnect/shell/xpcshell.cpp +1817 -0
- data/vendor/tracemonkey/xpconnect/shell/xpcshellMacUtils.h +43 -0
- data/vendor/tracemonkey/xpconnect/shell/xpcshellMacUtils.mm +54 -0
- data/vendor/tracemonkey/xpconnect/src/Makefile.in +228 -0
- data/vendor/tracemonkey/xpconnect/src/README +3 -0
- data/vendor/tracemonkey/xpconnect/src/XPCCrossOriginWrapper.cpp +1186 -0
- data/vendor/tracemonkey/xpconnect/src/XPCDispConvert.cpp +593 -0
- data/vendor/tracemonkey/xpconnect/src/XPCDispInlines.h +667 -0
- data/vendor/tracemonkey/xpconnect/src/XPCDispInterface.cpp +383 -0
- data/vendor/tracemonkey/xpconnect/src/XPCDispObject.cpp +516 -0
- data/vendor/tracemonkey/xpconnect/src/XPCDispParamPropJSClass.cpp +223 -0
- data/vendor/tracemonkey/xpconnect/src/XPCDispParams.cpp +103 -0
- data/vendor/tracemonkey/xpconnect/src/XPCDispPrivate.h +1401 -0
- data/vendor/tracemonkey/xpconnect/src/XPCDispTearOff.cpp +547 -0
- data/vendor/tracemonkey/xpconnect/src/XPCDispTypeInfo.cpp +471 -0
- data/vendor/tracemonkey/xpconnect/src/XPCIDispatchClassInfo.cpp +139 -0
- data/vendor/tracemonkey/xpconnect/src/XPCIDispatchExtension.cpp +362 -0
- data/vendor/tracemonkey/xpconnect/src/XPCNativeWrapper.cpp +1350 -0
- data/vendor/tracemonkey/xpconnect/src/XPCNativeWrapper.h +88 -0
- data/vendor/tracemonkey/xpconnect/src/XPCSafeJSObjectWrapper.cpp +1148 -0
- data/vendor/tracemonkey/xpconnect/src/XPCSystemOnlyWrapper.cpp +718 -0
- data/vendor/tracemonkey/xpconnect/src/XPCWrapper.cpp +850 -0
- data/vendor/tracemonkey/xpconnect/src/XPCWrapper.h +394 -0
- data/vendor/tracemonkey/xpconnect/src/dom_quickstubs.qsconf +568 -0
- data/vendor/tracemonkey/xpconnect/src/nsDispatchSupport.cpp +348 -0
- data/vendor/tracemonkey/xpconnect/src/nsScriptError.cpp +201 -0
- data/vendor/tracemonkey/xpconnect/src/nsXPConnect.cpp +2609 -0
- data/vendor/tracemonkey/xpconnect/src/qsgen.py +1487 -0
- data/vendor/tracemonkey/xpconnect/src/xpc.msg +217 -0
- data/vendor/tracemonkey/xpconnect/src/xpcJSWeakReference.cpp +148 -0
- data/vendor/tracemonkey/xpconnect/src/xpcJSWeakReference.h +56 -0
- data/vendor/tracemonkey/xpconnect/src/xpccallcontext.cpp +579 -0
- data/vendor/tracemonkey/xpconnect/src/xpccomponents.cpp +4144 -0
- data/vendor/tracemonkey/xpconnect/src/xpccontext.cpp +115 -0
- data/vendor/tracemonkey/xpconnect/src/xpcconvert.cpp +2298 -0
- data/vendor/tracemonkey/xpconnect/src/xpcdebug.cpp +481 -0
- data/vendor/tracemonkey/xpconnect/src/xpcexception.cpp +502 -0
- data/vendor/tracemonkey/xpconnect/src/xpcforwards.h +114 -0
- data/vendor/tracemonkey/xpconnect/src/xpcinlines.h +772 -0
- data/vendor/tracemonkey/xpconnect/src/xpcjsid.cpp +1025 -0
- data/vendor/tracemonkey/xpconnect/src/xpcjsruntime.cpp +1342 -0
- data/vendor/tracemonkey/xpconnect/src/xpclog.cpp +128 -0
- data/vendor/tracemonkey/xpconnect/src/xpclog.h +101 -0
- data/vendor/tracemonkey/xpconnect/src/xpcmaps.cpp +761 -0
- data/vendor/tracemonkey/xpconnect/src/xpcmaps.h +713 -0
- data/vendor/tracemonkey/xpconnect/src/xpcmodule.cpp +136 -0
- data/vendor/tracemonkey/xpconnect/src/xpcprivate.h +4138 -0
- data/vendor/tracemonkey/xpconnect/src/xpcquickstubs.cpp +1128 -0
- data/vendor/tracemonkey/xpconnect/src/xpcquickstubs.h +480 -0
- data/vendor/tracemonkey/xpconnect/src/xpcruntimesvc.cpp +179 -0
- data/vendor/tracemonkey/xpconnect/src/xpcstack.cpp +342 -0
- data/vendor/tracemonkey/xpconnect/src/xpcstring.cpp +139 -0
- data/vendor/tracemonkey/xpconnect/src/xpcthreadcontext.cpp +599 -0
- data/vendor/tracemonkey/xpconnect/src/xpcthrower.cpp +399 -0
- data/vendor/tracemonkey/xpconnect/src/xpcvariant.cpp +850 -0
- data/vendor/tracemonkey/xpconnect/src/xpcwrappedjs.cpp +670 -0
- data/vendor/tracemonkey/xpconnect/src/xpcwrappedjsclass.cpp +2015 -0
- data/vendor/tracemonkey/xpconnect/src/xpcwrappednative.cpp +3482 -0
- data/vendor/tracemonkey/xpconnect/src/xpcwrappednativeinfo.cpp +945 -0
- data/vendor/tracemonkey/xpconnect/src/xpcwrappednativejsops.cpp +2003 -0
- data/vendor/tracemonkey/xpconnect/src/xpcwrappednativeproto.cpp +302 -0
- data/vendor/tracemonkey/xpconnect/src/xpcwrappednativescope.cpp +991 -0
- data/vendor/tracemonkey/xpconnect/tests/Makefile.in +75 -0
- data/vendor/tracemonkey/xpconnect/tests/TestXPC.cpp +785 -0
- data/vendor/tracemonkey/xpconnect/tests/chrome/Makefile.in +51 -0
- data/vendor/tracemonkey/xpconnect/tests/chrome/test_bug500931.xul +43 -0
- data/vendor/tracemonkey/xpconnect/tests/components/Makefile.in +85 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_array.cpp +388 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_attributes.cpp +305 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_calljs.cpp +135 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_child.cpp +225 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_const.cpp +76 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_domstring.cpp +118 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_echo.cpp +616 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_in.cpp +204 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_inout.cpp +171 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_module.cpp +77 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_multiple.cpp +554 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_noisy.cpp +154 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_out.cpp +335 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_overloaded.cpp +250 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_private.h +192 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_string.cpp +185 -0
- data/vendor/tracemonkey/xpconnect/tests/components/xpctest_variant.cpp +355 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/StdAfx.cpp +12 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/StdAfx.h +28 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/XPCDispUtilities.h +28 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/XPCIDispatchTest.cpp +86 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/XPCIDispatchTest.def +9 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/XPCIDispatchTest.dsp +318 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/XPCIDispatchTest.dsw +29 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/XPCIDispatchTest.idl +454 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/XPCIDispatchTest.rc +145 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispSimple.cpp +44 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispSimple.h +56 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispSimple.rgs +23 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestArrays.cpp +221 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestArrays.h +53 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestArrays.rgs +23 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestMethods.cpp +699 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestMethods.h +138 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestMethods.rgs +23 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestNoIDispatch.cpp +23 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestNoIDispatch.h +41 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestNoIDispatch.rgs +23 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestProperties.cpp +256 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestProperties.h +88 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestProperties.rgs +23 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestScriptOff.cpp +23 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestScriptOff.h +43 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestScriptOff.rgs +23 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestScriptOn.cpp +29 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestScriptOn.h +45 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestScriptOn.rgs +23 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestWrappedJS.cpp +177 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestWrappedJS.h +50 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/nsXPCDispTestWrappedJS.rgs +23 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/COM/resource.h +36 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/Tests/WrappedCOM/Arrays/XPCIDispatchArrayTests.js +54 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/Tests/WrappedCOM/Attributes/XPCIDispatchAttributeTests.js +150 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/Tests/WrappedCOM/General/XPCIDispatchInstantiations.js +122 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/Tests/WrappedCOM/General/XPCStress.js +58 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/Tests/WrappedCOM/Methods/XPCIDispatchMethodTests.js +376 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/Tests/WrappedCOM/shell.js +377 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/Tests/WrappedJS/General/XPCIDispatchTestWrappedJS.js +76 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/Tests/WrappedJS/shell.js +377 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/Tests/exectests.cmd +1 -0
- data/vendor/tracemonkey/xpconnect/tests/idispatch/Tests/jsDriver.pl +1288 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/Makefile.in +61 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/xpctest.idl +312 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/xpctest2.idl +51 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/xpctest_attributes.idl +67 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/xpctest_calljs.idl +59 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/xpctest_const.idl +61 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/xpctest_domstring.idl +59 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/xpctest_in.idl +88 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/xpctest_inout.idl +86 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/xpctest_multiple.idl +77 -0
- data/vendor/tracemonkey/xpconnect/tests/idl/xpctest_out.idl +142 -0
- data/vendor/tracemonkey/xpconnect/tests/js/checkid.js +82 -0
- data/vendor/tracemonkey/xpconnect/tests/js/evaluate.js +311 -0
- data/vendor/tracemonkey/xpconnect/tests/js/exceptions-2.js +153 -0
- data/vendor/tracemonkey/xpconnect/tests/js/exceptions-3.js +194 -0
- data/vendor/tracemonkey/xpconnect/tests/js/exceptions-4.js +297 -0
- data/vendor/tracemonkey/xpconnect/tests/js/exceptions-5.js +343 -0
- data/vendor/tracemonkey/xpconnect/tests/js/exceptions.js +230 -0
- data/vendor/tracemonkey/xpconnect/tests/js/javascript.js +96 -0
- data/vendor/tracemonkey/xpconnect/tests/js/multiple-2.js +151 -0
- data/vendor/tracemonkey/xpconnect/tests/js/multiple-3.js +148 -0
- data/vendor/tracemonkey/xpconnect/tests/js/multiple-4.js +152 -0
- data/vendor/tracemonkey/xpconnect/tests/js/multiple.js +137 -0
- data/vendor/tracemonkey/xpconnect/tests/js/notscriptable.js +104 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/simpletest.js +36 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/speed.js +60 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/testxpc.js +464 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/threads.js +74 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/try.js +27 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_array.js +308 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_callcontext.js +68 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_echo.js +636 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_enum_and_sort.js +28 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_enum_constants.js +15 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_enum_create.js +200 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_exceptions.js +167 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_ids.js +135 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_observer.js +36 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_overloaded.js +14 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_primitives.js +141 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_propertybag.js +36 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_variant.js +339 -0
- data/vendor/tracemonkey/xpconnect/tests/js/old/xpctest_variant_array.js +30 -0
- data/vendor/tracemonkey/xpconnect/tests/js/readonlyattributes.js +74 -0
- data/vendor/tracemonkey/xpconnect/tests/js/readwriteattributes.js +101 -0
- data/vendor/tracemonkey/xpconnect/tests/js/scriptable.js +120 -0
- data/vendor/tracemonkey/xpconnect/tests/js/testin.js +203 -0
- data/vendor/tracemonkey/xpconnect/tests/js/xpcfun.js +234 -0
- data/vendor/tracemonkey/xpconnect/tests/js/xpctest_primitives.js +200 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/Makefile.in +66 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/bug500931_helper.html +7 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/inner.html +7 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug361111.xul +29 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug384632.html +32 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug390488.html +65 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug393269.html +46 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug396851.html +43 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug428021.html +41 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug446584.html +49 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug448587.html +31 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug462428.html +42 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug478438.html +66 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug484107.html +100 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug484459.html +36 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_bug500691.html +28 -0
- data/vendor/tracemonkey/xpconnect/tests/mochitest/test_wrappers.html +116 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/bogus_element_type.jsm +1 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/bogus_exports_type.jsm +1 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/bug451678_subscript.js +2 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/component_import.js +144 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/recursive_importA.jsm +44 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/recursive_importB.jsm +45 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/syntax_error.jsm +1 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/test_bogus_files.js +88 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/test_bug408412.js +51 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/test_bug451678.js +52 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/test_bug_442086.js +68 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/test_import.js +127 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/test_js_weak_references.js +63 -0
- data/vendor/tracemonkey/xpconnect/tests/unit/test_recursive_import.js +62 -0
- data/vendor/tracemonkey/xpconnect/tools/Makefile.in +49 -0
- data/vendor/tracemonkey/xpconnect/tools/idl/Makefile.in +53 -0
- data/vendor/tracemonkey/xpconnect/tools/idl/nsIXPCToolsCompiler.idl +60 -0
- data/vendor/tracemonkey/xpconnect/tools/idl/nsIXPCToolsProfiler.idl +57 -0
- data/vendor/tracemonkey/xpconnect/tools/js/CompileJSFiles.js +28 -0
- data/vendor/tracemonkey/xpconnect/tools/js/ListJSFiles.js +18 -0
- data/vendor/tracemonkey/xpconnect/tools/src/Makefile.in +76 -0
- data/vendor/tracemonkey/xpconnect/tools/src/nsXPCToolsCompiler.cpp +161 -0
- data/vendor/tracemonkey/xpconnect/tools/src/nsXPCToolsModule.cpp +65 -0
- data/vendor/tracemonkey/xpconnect/tools/src/nsXPCToolsProfiler.cpp +370 -0
- data/vendor/tracemonkey/xpconnect/tools/src/xpctools_private.h +236 -0
- metadata +1164 -0
@@ -0,0 +1,641 @@
|
|
1
|
+
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*-
|
2
|
+
*
|
3
|
+
* ***** BEGIN LICENSE BLOCK *****
|
4
|
+
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
5
|
+
*
|
6
|
+
* The contents of this file are subject to the Mozilla Public License Version
|
7
|
+
* 1.1 (the "License"); you may not use this file except in compliance with
|
8
|
+
* the License. You may obtain a copy of the License at
|
9
|
+
* http://www.mozilla.org/MPL/
|
10
|
+
*
|
11
|
+
* Software distributed under the License is distributed on an "AS IS" basis,
|
12
|
+
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
13
|
+
* for the specific language governing rights and limitations under the
|
14
|
+
* License.
|
15
|
+
*
|
16
|
+
* The Original Code is Mozilla Communicator client code, released
|
17
|
+
* March 31, 1998.
|
18
|
+
*
|
19
|
+
* The Initial Developer of the Original Code is
|
20
|
+
* Netscape Communications Corporation.
|
21
|
+
* Portions created by the Initial Developer are Copyright (C) 1998
|
22
|
+
* the Initial Developer. All Rights Reserved.
|
23
|
+
*
|
24
|
+
* Contributor(s):
|
25
|
+
*
|
26
|
+
* Alternatively, the contents of this file may be used under the terms of
|
27
|
+
* either of the GNU General Public License Version 2 or later (the "GPL"),
|
28
|
+
* or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
29
|
+
* in which case the provisions of the GPL or the LGPL are applicable instead
|
30
|
+
* of those above. If you wish to allow use of your version of this file only
|
31
|
+
* under the terms of either the GPL or the LGPL, and not to allow others to
|
32
|
+
* use your version of this file under the terms of the MPL, indicate your
|
33
|
+
* decision by deleting the provisions above and replace them with the notice
|
34
|
+
* and other provisions required by the GPL or the LGPL. If you do not delete
|
35
|
+
* the provisions above, a recipient may use your version of this file under
|
36
|
+
* the terms of any one of the MPL, the GPL or the LGPL.
|
37
|
+
*
|
38
|
+
* ***** END LICENSE BLOCK ***** */
|
39
|
+
|
40
|
+
#ifndef jsstr_h___
|
41
|
+
#define jsstr_h___
|
42
|
+
/*
|
43
|
+
* JS string type implementation.
|
44
|
+
*
|
45
|
+
* A JS string is a counted array of unicode characters. To support handoff
|
46
|
+
* of API client memory, the chars are allocated separately from the length,
|
47
|
+
* necessitating a pointer after the count, to form a separately allocated
|
48
|
+
* string descriptor. String descriptors are GC'ed, while their chars are
|
49
|
+
* allocated from the malloc heap.
|
50
|
+
*/
|
51
|
+
#include <ctype.h>
|
52
|
+
#include "jspubtd.h"
|
53
|
+
#include "jsprvtd.h"
|
54
|
+
|
55
|
+
JS_BEGIN_EXTERN_C
|
56
|
+
|
57
|
+
/*
|
58
|
+
* The GC-thing "string" type.
|
59
|
+
*
|
60
|
+
* When the JSSTRFLAG_DEPENDENT bit of the length field is unset, the u.chars
|
61
|
+
* field points to a flat character array owned by its GC-thing descriptor.
|
62
|
+
* The array is terminated at index length by a zero character and the size of
|
63
|
+
* the array in bytes is (length + 1) * sizeof(jschar). The terminator is
|
64
|
+
* purely a backstop, in case the chars pointer flows out to native code that
|
65
|
+
* requires \u0000 termination.
|
66
|
+
*
|
67
|
+
* A flat string with JSSTRFLAG_MUTABLE set means that the string is accessible
|
68
|
+
* only from one thread and it is possible to turn it into a dependent string
|
69
|
+
* of the same length to optimize js_ConcatStrings. It is also possible to grow
|
70
|
+
* such a string, but extreme care must be taken to ensure that no other code
|
71
|
+
* relies on the original length of the string.
|
72
|
+
*
|
73
|
+
* A flat string with JSSTRFLAG_ATOMIZED set means that the string is hashed as
|
74
|
+
* an atom. This flag is used to avoid re-hashing the already-atomized string.
|
75
|
+
*
|
76
|
+
* When JSSTRFLAG_DEPENDENT is set, the string depends on characters of another
|
77
|
+
* string strongly referenced by the u.base field. The base member may point to
|
78
|
+
* another dependent string if JSSTRING_CHARS has not been called yet.
|
79
|
+
*
|
80
|
+
* JSSTRFLAG_PREFIX determines the kind of the dependent string. When the flag
|
81
|
+
* is unset, the length field encodes both starting position relative to the
|
82
|
+
* base string and the number of characters in the dependent string, see
|
83
|
+
* JSSTRDEP_START_MASK and JSSTRDEP_LENGTH_MASK macros below for details.
|
84
|
+
*
|
85
|
+
* When JSSTRFLAG_PREFIX is set, the dependent string is a prefix of the base
|
86
|
+
* string. The number of characters in the prefix is encoded using all non-flag
|
87
|
+
* bits of the length field and spans the same 0 .. SIZE_T_MAX/4 range as the
|
88
|
+
* length of the flat string.
|
89
|
+
*
|
90
|
+
* NB: Always use the JSSTRING_LENGTH and JSSTRING_CHARS accessor macros.
|
91
|
+
*/
|
92
|
+
struct JSString {
|
93
|
+
size_t length;
|
94
|
+
union {
|
95
|
+
jschar *chars;
|
96
|
+
JSString *base;
|
97
|
+
} u;
|
98
|
+
};
|
99
|
+
|
100
|
+
/*
|
101
|
+
* Definitions for flags stored in the high order bits of JSString.length.
|
102
|
+
* JSSTRFLAG_PREFIX and JSSTRFLAG_MUTABLE are two aliases for the same value.
|
103
|
+
* JSSTRFLAG_PREFIX should be used only if JSSTRFLAG_DEPENDENT is set and
|
104
|
+
* JSSTRFLAG_MUTABLE should be used only if the string is flat.
|
105
|
+
* JSSTRFLAG_ATOMIZED is used only with the flat immutable strings.
|
106
|
+
*/
|
107
|
+
#define JSSTRFLAG_DEPENDENT JSSTRING_BIT(JS_BITS_PER_WORD - 1)
|
108
|
+
#define JSSTRFLAG_PREFIX JSSTRING_BIT(JS_BITS_PER_WORD - 2)
|
109
|
+
#define JSSTRFLAG_MUTABLE JSSTRFLAG_PREFIX
|
110
|
+
#define JSSTRFLAG_ATOMIZED JSSTRING_BIT(JS_BITS_PER_WORD - 3)
|
111
|
+
|
112
|
+
#define JSSTRING_LENGTH_BITS (JS_BITS_PER_WORD - 3)
|
113
|
+
#define JSSTRING_LENGTH_MASK JSSTRING_BITMASK(JSSTRING_LENGTH_BITS)
|
114
|
+
|
115
|
+
/* Universal JSString type inquiry and accessor macros. */
|
116
|
+
#define JSSTRING_BIT(n) ((size_t)1 << (n))
|
117
|
+
#define JSSTRING_BITMASK(n) (JSSTRING_BIT(n) - 1)
|
118
|
+
#define JSSTRING_HAS_FLAG(str,flg) ((str)->length & (flg))
|
119
|
+
#define JSSTRING_IS_DEPENDENT(str) JSSTRING_HAS_FLAG(str, JSSTRFLAG_DEPENDENT)
|
120
|
+
#define JSSTRING_IS_FLAT(str) (!JSSTRING_IS_DEPENDENT(str))
|
121
|
+
#define JSSTRING_IS_MUTABLE(str) (((str)->length & (JSSTRFLAG_DEPENDENT | \
|
122
|
+
JSSTRFLAG_MUTABLE)) == \
|
123
|
+
JSSTRFLAG_MUTABLE)
|
124
|
+
#define JSSTRING_IS_ATOMIZED(str) (((str)->length & (JSSTRFLAG_DEPENDENT | \
|
125
|
+
JSSTRFLAG_ATOMIZED)) ==\
|
126
|
+
JSSTRFLAG_ATOMIZED)
|
127
|
+
|
128
|
+
#define JSSTRING_CHARS(str) (JSSTRING_IS_DEPENDENT(str) \
|
129
|
+
? JSSTRDEP_CHARS(str) \
|
130
|
+
: JSFLATSTR_CHARS(str))
|
131
|
+
#define JSSTRING_LENGTH(str) (JSSTRING_IS_DEPENDENT(str) \
|
132
|
+
? JSSTRDEP_LENGTH(str) \
|
133
|
+
: JSFLATSTR_LENGTH(str))
|
134
|
+
|
135
|
+
#define JSSTRING_CHARS_AND_LENGTH(str, chars_, length_) \
|
136
|
+
((void)(JSSTRING_IS_DEPENDENT(str) \
|
137
|
+
? ((length_) = JSSTRDEP_LENGTH(str), \
|
138
|
+
(chars_) = JSSTRDEP_CHARS(str)) \
|
139
|
+
: ((length_) = JSFLATSTR_LENGTH(str), \
|
140
|
+
(chars_) = JSFLATSTR_CHARS(str))))
|
141
|
+
|
142
|
+
#define JSSTRING_CHARS_AND_END(str, chars_, end) \
|
143
|
+
((void)((end) = JSSTRING_IS_DEPENDENT(str) \
|
144
|
+
? JSSTRDEP_LENGTH(str) + ((chars_) = JSSTRDEP_CHARS(str)) \
|
145
|
+
: JSFLATSTR_LENGTH(str) + ((chars_) = JSFLATSTR_CHARS(str))))
|
146
|
+
|
147
|
+
/* Specific flat string initializer and accessor macros. */
|
148
|
+
#define JSFLATSTR_INIT(str, chars_, length_) \
|
149
|
+
((void)(JS_ASSERT(((length_) & ~JSSTRING_LENGTH_MASK) == 0), \
|
150
|
+
(str)->length = (length_), (str)->u.chars = (chars_)))
|
151
|
+
|
152
|
+
#define JSFLATSTR_LENGTH(str) \
|
153
|
+
(JS_ASSERT(JSSTRING_IS_FLAT(str)), (str)->length & JSSTRING_LENGTH_MASK)
|
154
|
+
|
155
|
+
#define JSFLATSTR_CHARS(str) \
|
156
|
+
(JS_ASSERT(JSSTRING_IS_FLAT(str)), (str)->u.chars)
|
157
|
+
|
158
|
+
/*
|
159
|
+
* Macros to manipulate atomized and mutable flags of flat strings. It is safe
|
160
|
+
* to use these without extra locking due to the following properties:
|
161
|
+
*
|
162
|
+
* * We do not have a macro like JSFLATSTR_CLEAR_ATOMIZED as a string
|
163
|
+
* remains atomized until the GC collects it.
|
164
|
+
*
|
165
|
+
* * A thread may call JSFLATSTR_SET_MUTABLE only when it is the only thread
|
166
|
+
* accessing the string until a later call to JSFLATSTR_CLEAR_MUTABLE.
|
167
|
+
*
|
168
|
+
* * Multiple threads can call JSFLATSTR_CLEAR_MUTABLE but the macro
|
169
|
+
* actually clears the mutable flag only when the flag is set -- in which
|
170
|
+
* case only one thread can access the string (see previous property).
|
171
|
+
*
|
172
|
+
* Thus, when multiple threads access the string, JSFLATSTR_SET_ATOMIZED is
|
173
|
+
* the only macro that can update the length field of the string by changing
|
174
|
+
* the mutable bit from 0 to 1. We call the macro only after the string has
|
175
|
+
* been hashed. When some threads in js_ValueToStringId see that the flag is
|
176
|
+
* set, it knows that the string was atomized.
|
177
|
+
*
|
178
|
+
* On the other hand, if the thread sees that the flag is unset, it could be
|
179
|
+
* seeing a stale value when another thread has just atomized the string and
|
180
|
+
* set the flag. But this can lead only to an extra call to js_AtomizeString.
|
181
|
+
* This function would find that the string was already hashed and return it
|
182
|
+
* with the atomized bit set.
|
183
|
+
*/
|
184
|
+
#define JSFLATSTR_SET_ATOMIZED(str) \
|
185
|
+
((void)(JS_ASSERT(JSSTRING_IS_FLAT(str) && !JSSTRING_IS_MUTABLE(str)), \
|
186
|
+
(str)->length |= JSSTRFLAG_ATOMIZED))
|
187
|
+
|
188
|
+
#define JSFLATSTR_SET_MUTABLE(str) \
|
189
|
+
((void)(JS_ASSERT(JSSTRING_IS_FLAT(str) && !JSSTRING_IS_ATOMIZED(str)), \
|
190
|
+
(str)->length |= JSSTRFLAG_MUTABLE))
|
191
|
+
|
192
|
+
#define JSFLATSTR_CLEAR_MUTABLE(str) \
|
193
|
+
((void)(JS_ASSERT(JSSTRING_IS_FLAT(str)), \
|
194
|
+
JSSTRING_HAS_FLAG(str, JSSTRFLAG_MUTABLE) && \
|
195
|
+
((str)->length &= ~JSSTRFLAG_MUTABLE)))
|
196
|
+
|
197
|
+
/* Specific dependent string shift/mask accessor and mutator macros. */
|
198
|
+
#define JSSTRDEP_START_BITS (JSSTRING_LENGTH_BITS-JSSTRDEP_LENGTH_BITS)
|
199
|
+
#define JSSTRDEP_START_SHIFT JSSTRDEP_LENGTH_BITS
|
200
|
+
#define JSSTRDEP_START_MASK JSSTRING_BITMASK(JSSTRDEP_START_BITS)
|
201
|
+
#define JSSTRDEP_LENGTH_BITS (JSSTRING_LENGTH_BITS / 2)
|
202
|
+
#define JSSTRDEP_LENGTH_MASK JSSTRING_BITMASK(JSSTRDEP_LENGTH_BITS)
|
203
|
+
|
204
|
+
#define JSSTRDEP_IS_PREFIX(str) JSSTRING_HAS_FLAG(str, JSSTRFLAG_PREFIX)
|
205
|
+
|
206
|
+
#define JSSTRDEP_START(str) (JSSTRDEP_IS_PREFIX(str) ? 0 \
|
207
|
+
: (((str)->length \
|
208
|
+
>> JSSTRDEP_START_SHIFT) \
|
209
|
+
& JSSTRDEP_START_MASK))
|
210
|
+
#define JSSTRDEP_LENGTH(str) ((str)->length \
|
211
|
+
& (JSSTRDEP_IS_PREFIX(str) \
|
212
|
+
? JSSTRING_LENGTH_MASK \
|
213
|
+
: JSSTRDEP_LENGTH_MASK))
|
214
|
+
|
215
|
+
#define JSSTRDEP_INIT(str,bstr,off,len) \
|
216
|
+
((str)->length = JSSTRFLAG_DEPENDENT \
|
217
|
+
| ((off) << JSSTRDEP_START_SHIFT) \
|
218
|
+
| (len), \
|
219
|
+
(str)->u.base = (bstr))
|
220
|
+
|
221
|
+
#define JSPREFIX_INIT(str,bstr,len) \
|
222
|
+
((str)->length = JSSTRFLAG_DEPENDENT | JSSTRFLAG_PREFIX | (len), \
|
223
|
+
(str)->u.base = (bstr))
|
224
|
+
|
225
|
+
#define JSSTRDEP_BASE(str) ((str)->u.base)
|
226
|
+
#define JSPREFIX_BASE(str) JSSTRDEP_BASE(str)
|
227
|
+
#define JSPREFIX_SET_BASE(str,bstr) ((str)->u.base = (bstr))
|
228
|
+
|
229
|
+
#define JSSTRDEP_CHARS(str) \
|
230
|
+
(JSSTRING_IS_DEPENDENT(JSSTRDEP_BASE(str)) \
|
231
|
+
? js_GetDependentStringChars(str) \
|
232
|
+
: JSFLATSTR_CHARS(JSSTRDEP_BASE(str)) + JSSTRDEP_START(str))
|
233
|
+
|
234
|
+
extern size_t
|
235
|
+
js_MinimizeDependentStrings(JSString *str, int level, JSString **basep);
|
236
|
+
|
237
|
+
extern jschar *
|
238
|
+
js_GetDependentStringChars(JSString *str);
|
239
|
+
|
240
|
+
extern const jschar *
|
241
|
+
js_GetStringChars(JSContext *cx, JSString *str);
|
242
|
+
|
243
|
+
extern JSString *
|
244
|
+
js_ConcatStrings(JSContext *cx, JSString *left, JSString *right);
|
245
|
+
|
246
|
+
extern const jschar *
|
247
|
+
js_UndependString(JSContext *cx, JSString *str);
|
248
|
+
|
249
|
+
extern JSBool
|
250
|
+
js_MakeStringImmutable(JSContext *cx, JSString *str);
|
251
|
+
|
252
|
+
typedef struct JSCharBuffer {
|
253
|
+
size_t length;
|
254
|
+
jschar *chars;
|
255
|
+
} JSCharBuffer;
|
256
|
+
|
257
|
+
struct JSSubString {
|
258
|
+
size_t length;
|
259
|
+
const jschar *chars;
|
260
|
+
};
|
261
|
+
|
262
|
+
extern jschar js_empty_ucstr[];
|
263
|
+
extern JSSubString js_EmptySubString;
|
264
|
+
|
265
|
+
/* Unicode character attribute lookup tables. */
|
266
|
+
extern const uint8 js_X[];
|
267
|
+
extern const uint8 js_Y[];
|
268
|
+
extern const uint32 js_A[];
|
269
|
+
|
270
|
+
/* Enumerated Unicode general category types. */
|
271
|
+
typedef enum JSCharType {
|
272
|
+
JSCT_UNASSIGNED = 0,
|
273
|
+
JSCT_UPPERCASE_LETTER = 1,
|
274
|
+
JSCT_LOWERCASE_LETTER = 2,
|
275
|
+
JSCT_TITLECASE_LETTER = 3,
|
276
|
+
JSCT_MODIFIER_LETTER = 4,
|
277
|
+
JSCT_OTHER_LETTER = 5,
|
278
|
+
JSCT_NON_SPACING_MARK = 6,
|
279
|
+
JSCT_ENCLOSING_MARK = 7,
|
280
|
+
JSCT_COMBINING_SPACING_MARK = 8,
|
281
|
+
JSCT_DECIMAL_DIGIT_NUMBER = 9,
|
282
|
+
JSCT_LETTER_NUMBER = 10,
|
283
|
+
JSCT_OTHER_NUMBER = 11,
|
284
|
+
JSCT_SPACE_SEPARATOR = 12,
|
285
|
+
JSCT_LINE_SEPARATOR = 13,
|
286
|
+
JSCT_PARAGRAPH_SEPARATOR = 14,
|
287
|
+
JSCT_CONTROL = 15,
|
288
|
+
JSCT_FORMAT = 16,
|
289
|
+
JSCT_PRIVATE_USE = 18,
|
290
|
+
JSCT_SURROGATE = 19,
|
291
|
+
JSCT_DASH_PUNCTUATION = 20,
|
292
|
+
JSCT_START_PUNCTUATION = 21,
|
293
|
+
JSCT_END_PUNCTUATION = 22,
|
294
|
+
JSCT_CONNECTOR_PUNCTUATION = 23,
|
295
|
+
JSCT_OTHER_PUNCTUATION = 24,
|
296
|
+
JSCT_MATH_SYMBOL = 25,
|
297
|
+
JSCT_CURRENCY_SYMBOL = 26,
|
298
|
+
JSCT_MODIFIER_SYMBOL = 27,
|
299
|
+
JSCT_OTHER_SYMBOL = 28
|
300
|
+
} JSCharType;
|
301
|
+
|
302
|
+
/* Character classifying and mapping macros, based on java.lang.Character. */
|
303
|
+
#define JS_CCODE(c) (js_A[js_Y[(js_X[(uint16)(c)>>6]<<6)|((c)&0x3F)]])
|
304
|
+
#define JS_CTYPE(c) (JS_CCODE(c) & 0x1F)
|
305
|
+
|
306
|
+
#define JS_ISALPHA(c) ((((1 << JSCT_UPPERCASE_LETTER) | \
|
307
|
+
(1 << JSCT_LOWERCASE_LETTER) | \
|
308
|
+
(1 << JSCT_TITLECASE_LETTER) | \
|
309
|
+
(1 << JSCT_MODIFIER_LETTER) | \
|
310
|
+
(1 << JSCT_OTHER_LETTER)) \
|
311
|
+
>> JS_CTYPE(c)) & 1)
|
312
|
+
|
313
|
+
#define JS_ISALNUM(c) ((((1 << JSCT_UPPERCASE_LETTER) | \
|
314
|
+
(1 << JSCT_LOWERCASE_LETTER) | \
|
315
|
+
(1 << JSCT_TITLECASE_LETTER) | \
|
316
|
+
(1 << JSCT_MODIFIER_LETTER) | \
|
317
|
+
(1 << JSCT_OTHER_LETTER) | \
|
318
|
+
(1 << JSCT_DECIMAL_DIGIT_NUMBER)) \
|
319
|
+
>> JS_CTYPE(c)) & 1)
|
320
|
+
|
321
|
+
/* A unicode letter, suitable for use in an identifier. */
|
322
|
+
#define JS_ISLETTER(c) ((((1 << JSCT_UPPERCASE_LETTER) | \
|
323
|
+
(1 << JSCT_LOWERCASE_LETTER) | \
|
324
|
+
(1 << JSCT_TITLECASE_LETTER) | \
|
325
|
+
(1 << JSCT_MODIFIER_LETTER) | \
|
326
|
+
(1 << JSCT_OTHER_LETTER) | \
|
327
|
+
(1 << JSCT_LETTER_NUMBER)) \
|
328
|
+
>> JS_CTYPE(c)) & 1)
|
329
|
+
|
330
|
+
/*
|
331
|
+
* 'IdentifierPart' from ECMA grammar, is Unicode letter or combining mark or
|
332
|
+
* digit or connector punctuation.
|
333
|
+
*/
|
334
|
+
#define JS_ISIDPART(c) ((((1 << JSCT_UPPERCASE_LETTER) | \
|
335
|
+
(1 << JSCT_LOWERCASE_LETTER) | \
|
336
|
+
(1 << JSCT_TITLECASE_LETTER) | \
|
337
|
+
(1 << JSCT_MODIFIER_LETTER) | \
|
338
|
+
(1 << JSCT_OTHER_LETTER) | \
|
339
|
+
(1 << JSCT_LETTER_NUMBER) | \
|
340
|
+
(1 << JSCT_NON_SPACING_MARK) | \
|
341
|
+
(1 << JSCT_COMBINING_SPACING_MARK) | \
|
342
|
+
(1 << JSCT_DECIMAL_DIGIT_NUMBER) | \
|
343
|
+
(1 << JSCT_CONNECTOR_PUNCTUATION)) \
|
344
|
+
>> JS_CTYPE(c)) & 1)
|
345
|
+
|
346
|
+
/* Unicode control-format characters, ignored in input */
|
347
|
+
#define JS_ISFORMAT(c) (((1 << JSCT_FORMAT) >> JS_CTYPE(c)) & 1)
|
348
|
+
|
349
|
+
/*
|
350
|
+
* Per ECMA-262 15.10.2.6, these characters are the only ones that make up a
|
351
|
+
* "word", as far as a RegExp is concerned. If we want a Unicode-friendlier
|
352
|
+
* definition of "word", we should rename this macro to something regexp-y.
|
353
|
+
*/
|
354
|
+
#define JS_ISWORD(c) ((c) < 128 && (isalnum(c) || (c) == '_'))
|
355
|
+
|
356
|
+
#define JS_ISIDSTART(c) (JS_ISLETTER(c) || (c) == '_' || (c) == '$')
|
357
|
+
#define JS_ISIDENT(c) (JS_ISIDPART(c) || (c) == '_' || (c) == '$')
|
358
|
+
|
359
|
+
#define JS_ISXMLSPACE(c) ((c) == ' ' || (c) == '\t' || (c) == '\r' || \
|
360
|
+
(c) == '\n')
|
361
|
+
#define JS_ISXMLNSSTART(c) ((JS_CCODE(c) & 0x00000100) || (c) == '_')
|
362
|
+
#define JS_ISXMLNS(c) ((JS_CCODE(c) & 0x00000080) || (c) == '.' || \
|
363
|
+
(c) == '-' || (c) == '_')
|
364
|
+
#define JS_ISXMLNAMESTART(c) (JS_ISXMLNSSTART(c) || (c) == ':')
|
365
|
+
#define JS_ISXMLNAME(c) (JS_ISXMLNS(c) || (c) == ':')
|
366
|
+
|
367
|
+
#define JS_ISDIGIT(c) (JS_CTYPE(c) == JSCT_DECIMAL_DIGIT_NUMBER)
|
368
|
+
|
369
|
+
/* XXXbe unify on A/X/Y tbls, avoid ctype.h? */
|
370
|
+
/* XXXbe fs, etc. ? */
|
371
|
+
#define JS_ISSPACE(c) ((JS_CCODE(c) & 0x00070000) == 0x00040000)
|
372
|
+
#define JS_ISPRINT(c) ((c) < 128 && isprint(c))
|
373
|
+
|
374
|
+
#define JS_ISUPPER(c) (JS_CTYPE(c) == JSCT_UPPERCASE_LETTER)
|
375
|
+
#define JS_ISLOWER(c) (JS_CTYPE(c) == JSCT_LOWERCASE_LETTER)
|
376
|
+
|
377
|
+
#define JS_TOUPPER(c) ((jschar) ((JS_CCODE(c) & 0x00100000) \
|
378
|
+
? (c) - ((int32)JS_CCODE(c) >> 22) \
|
379
|
+
: (c)))
|
380
|
+
#define JS_TOLOWER(c) ((jschar) ((JS_CCODE(c) & 0x00200000) \
|
381
|
+
? (c) + ((int32)JS_CCODE(c) >> 22) \
|
382
|
+
: (c)))
|
383
|
+
|
384
|
+
/*
|
385
|
+
* Shorthands for ASCII (7-bit) decimal and hex conversion.
|
386
|
+
* Manually inline isdigit for performance; MSVC doesn't do this for us.
|
387
|
+
*/
|
388
|
+
#define JS7_ISDEC(c) ((((unsigned)(c)) - '0') <= 9)
|
389
|
+
#define JS7_UNDEC(c) ((c) - '0')
|
390
|
+
#define JS7_ISHEX(c) ((c) < 128 && isxdigit(c))
|
391
|
+
#define JS7_UNHEX(c) (uintN)(JS7_ISDEC(c) ? (c) - '0' : 10 + tolower(c) - 'a')
|
392
|
+
#define JS7_ISLET(c) ((c) < 128 && isalpha(c))
|
393
|
+
|
394
|
+
/* Initialize per-runtime string state for the first context in the runtime. */
|
395
|
+
extern JSBool
|
396
|
+
js_InitRuntimeStringState(JSContext *cx);
|
397
|
+
|
398
|
+
extern JSBool
|
399
|
+
js_InitDeflatedStringCache(JSRuntime *rt);
|
400
|
+
|
401
|
+
/*
|
402
|
+
* Maximum character code for which we will create a pinned unit string on
|
403
|
+
* demand -- see JSRuntime.unitStrings in jscntxt.h.
|
404
|
+
*/
|
405
|
+
#define UNIT_STRING_LIMIT 256U
|
406
|
+
|
407
|
+
/*
|
408
|
+
* Get the independent string containing only character code at index in str
|
409
|
+
* (backstopped with a zero character as usual for independent strings).
|
410
|
+
*/
|
411
|
+
extern JSString *
|
412
|
+
js_GetUnitString(JSContext *cx, JSString *str, size_t index);
|
413
|
+
|
414
|
+
extern void
|
415
|
+
js_FinishUnitStrings(JSRuntime *rt);
|
416
|
+
|
417
|
+
extern void
|
418
|
+
js_FinishRuntimeStringState(JSContext *cx);
|
419
|
+
|
420
|
+
extern void
|
421
|
+
js_FinishDeflatedStringCache(JSRuntime *rt);
|
422
|
+
|
423
|
+
/* Initialize the String class, returning its prototype object. */
|
424
|
+
extern JSClass js_StringClass;
|
425
|
+
|
426
|
+
extern JSObject *
|
427
|
+
js_InitStringClass(JSContext *cx, JSObject *obj);
|
428
|
+
|
429
|
+
extern const char js_escape_str[];
|
430
|
+
extern const char js_unescape_str[];
|
431
|
+
extern const char js_uneval_str[];
|
432
|
+
extern const char js_decodeURI_str[];
|
433
|
+
extern const char js_encodeURI_str[];
|
434
|
+
extern const char js_decodeURIComponent_str[];
|
435
|
+
extern const char js_encodeURIComponent_str[];
|
436
|
+
|
437
|
+
/* GC-allocate a string descriptor for the given malloc-allocated chars. */
|
438
|
+
extern JSString *
|
439
|
+
js_NewString(JSContext *cx, jschar *chars, size_t length);
|
440
|
+
|
441
|
+
extern JSString *
|
442
|
+
js_NewDependentString(JSContext *cx, JSString *base, size_t start,
|
443
|
+
size_t length);
|
444
|
+
|
445
|
+
/* Copy a counted string and GC-allocate a descriptor for it. */
|
446
|
+
extern JSString *
|
447
|
+
js_NewStringCopyN(JSContext *cx, const jschar *s, size_t n);
|
448
|
+
|
449
|
+
/* Copy a C string and GC-allocate a descriptor for it. */
|
450
|
+
extern JSString *
|
451
|
+
js_NewStringCopyZ(JSContext *cx, const jschar *s);
|
452
|
+
|
453
|
+
/*
|
454
|
+
* Free the chars held by str when it is finalized by the GC. When type is
|
455
|
+
* less then zero, it denotes an internal string. Otherwise it denotes the
|
456
|
+
* type of the external string allocated with JS_NewExternalString.
|
457
|
+
*
|
458
|
+
* This function always needs rt but can live with null cx.
|
459
|
+
*/
|
460
|
+
extern void
|
461
|
+
js_FinalizeStringRT(JSRuntime *rt, JSString *str, intN type, JSContext *cx);
|
462
|
+
|
463
|
+
/*
|
464
|
+
* Convert a value to a printable C string.
|
465
|
+
*/
|
466
|
+
typedef JSString *(*JSValueToStringFun)(JSContext *cx, jsval v);
|
467
|
+
|
468
|
+
extern JS_FRIEND_API(const char *)
|
469
|
+
js_ValueToPrintable(JSContext *cx, jsval v, JSValueToStringFun v2sfun);
|
470
|
+
|
471
|
+
#define js_ValueToPrintableString(cx,v) \
|
472
|
+
js_ValueToPrintable(cx, v, js_ValueToString)
|
473
|
+
|
474
|
+
#define js_ValueToPrintableSource(cx,v) \
|
475
|
+
js_ValueToPrintable(cx, v, js_ValueToSource)
|
476
|
+
|
477
|
+
/*
|
478
|
+
* Convert a value to a string, returning null after reporting an error,
|
479
|
+
* otherwise returning a new string reference.
|
480
|
+
*/
|
481
|
+
extern JS_FRIEND_API(JSString *)
|
482
|
+
js_ValueToString(JSContext *cx, jsval v);
|
483
|
+
|
484
|
+
/*
|
485
|
+
* Convert a value to its source expression, returning null after reporting
|
486
|
+
* an error, otherwise returning a new string reference.
|
487
|
+
*/
|
488
|
+
extern JS_FRIEND_API(JSString *)
|
489
|
+
js_ValueToSource(JSContext *cx, jsval v);
|
490
|
+
|
491
|
+
/*
|
492
|
+
* Compute a hash function from str. The caller can call this function even if
|
493
|
+
* str is not a GC-allocated thing.
|
494
|
+
*/
|
495
|
+
extern uint32
|
496
|
+
js_HashString(JSString *str);
|
497
|
+
|
498
|
+
/*
|
499
|
+
* Test if strings are equal. The caller can call the function even if str1
|
500
|
+
* or str2 are not GC-allocated things.
|
501
|
+
*/
|
502
|
+
extern JSBool
|
503
|
+
js_EqualStrings(JSString *str1, JSString *str2);
|
504
|
+
|
505
|
+
/*
|
506
|
+
* Return less than, equal to, or greater than zero depending on whether
|
507
|
+
* str1 is less than, equal to, or greater than str2.
|
508
|
+
*/
|
509
|
+
extern intN
|
510
|
+
js_CompareStrings(JSString *str1, JSString *str2);
|
511
|
+
|
512
|
+
/*
|
513
|
+
* Boyer-Moore-Horspool superlinear search for pat:patlen in text:textlen.
|
514
|
+
* The patlen argument must be positive and no greater than BMH_PATLEN_MAX.
|
515
|
+
* The start argument tells where in text to begin the search.
|
516
|
+
*
|
517
|
+
* Return the index of pat in text, or -1 if not found.
|
518
|
+
*/
|
519
|
+
#define BMH_CHARSET_SIZE 256 /* ISO-Latin-1 */
|
520
|
+
#define BMH_PATLEN_MAX 255 /* skip table element is uint8 */
|
521
|
+
|
522
|
+
#define BMH_BAD_PATTERN (-2) /* return value if pat is not ISO-Latin-1 */
|
523
|
+
|
524
|
+
extern jsint
|
525
|
+
js_BoyerMooreHorspool(const jschar *text, jsint textlen,
|
526
|
+
const jschar *pat, jsint patlen,
|
527
|
+
jsint start);
|
528
|
+
|
529
|
+
extern size_t
|
530
|
+
js_strlen(const jschar *s);
|
531
|
+
|
532
|
+
extern jschar *
|
533
|
+
js_strchr(const jschar *s, jschar c);
|
534
|
+
|
535
|
+
extern jschar *
|
536
|
+
js_strchr_limit(const jschar *s, jschar c, const jschar *limit);
|
537
|
+
|
538
|
+
#define js_strncpy(t, s, n) memcpy((t), (s), (n) * sizeof(jschar))
|
539
|
+
|
540
|
+
/*
|
541
|
+
* Return s advanced past any Unicode white space characters.
|
542
|
+
*/
|
543
|
+
extern const jschar *
|
544
|
+
js_SkipWhiteSpace(const jschar *s, const jschar *end);
|
545
|
+
|
546
|
+
/*
|
547
|
+
* Inflate bytes to JS chars and vice versa. Report out of memory via cx
|
548
|
+
* and return null on error, otherwise return the jschar or byte vector that
|
549
|
+
* was JS_malloc'ed. length is updated with the length of the new string in jschars.
|
550
|
+
*/
|
551
|
+
extern jschar *
|
552
|
+
js_InflateString(JSContext *cx, const char *bytes, size_t *length);
|
553
|
+
|
554
|
+
extern char *
|
555
|
+
js_DeflateString(JSContext *cx, const jschar *chars, size_t length);
|
556
|
+
|
557
|
+
/*
|
558
|
+
* Inflate bytes to JS chars into a buffer. 'chars' must be large enough for
|
559
|
+
* 'length' jschars. The buffer is NOT null-terminated. The destination length
|
560
|
+
* must be be initialized with the buffer size and will contain on return the
|
561
|
+
* number of copied chars.
|
562
|
+
*/
|
563
|
+
extern JSBool
|
564
|
+
js_InflateStringToBuffer(JSContext* cx, const char *bytes, size_t length,
|
565
|
+
jschar *chars, size_t* charsLength);
|
566
|
+
|
567
|
+
/*
|
568
|
+
* Get number of bytes in the deflated sequence of characters.
|
569
|
+
*/
|
570
|
+
extern size_t
|
571
|
+
js_GetDeflatedStringLength(JSContext *cx, const jschar *chars,
|
572
|
+
size_t charsLength);
|
573
|
+
|
574
|
+
/*
|
575
|
+
* Deflate JS chars to bytes into a buffer. 'bytes' must be large enough for
|
576
|
+
* 'length chars. The buffer is NOT null-terminated. The destination length
|
577
|
+
* must to be initialized with the buffer size and will contain on return the
|
578
|
+
* number of copied bytes.
|
579
|
+
*/
|
580
|
+
extern JSBool
|
581
|
+
js_DeflateStringToBuffer(JSContext* cx, const jschar *chars,
|
582
|
+
size_t charsLength, char *bytes, size_t* length);
|
583
|
+
|
584
|
+
/*
|
585
|
+
* Associate bytes with str in the deflated string cache, returning true on
|
586
|
+
* successful association, false on out of memory.
|
587
|
+
*/
|
588
|
+
extern JSBool
|
589
|
+
js_SetStringBytes(JSContext *cx, JSString *str, char *bytes, size_t length);
|
590
|
+
|
591
|
+
/*
|
592
|
+
* Find or create a deflated string cache entry for str that contains its
|
593
|
+
* characters chopped from Unicode code points into bytes.
|
594
|
+
*/
|
595
|
+
extern const char *
|
596
|
+
js_GetStringBytes(JSContext *cx, JSString *str);
|
597
|
+
|
598
|
+
/* Remove a deflated string cache entry associated with str if any. */
|
599
|
+
extern void
|
600
|
+
js_PurgeDeflatedStringCache(JSRuntime *rt, JSString *str);
|
601
|
+
|
602
|
+
JSBool
|
603
|
+
js_str_escape(JSContext *cx, JSObject *obj, uintN argc, jsval *argv,
|
604
|
+
jsval *rval);
|
605
|
+
|
606
|
+
/*
|
607
|
+
* Convert one UCS-4 char and write it into a UTF-8 buffer, which must be at
|
608
|
+
* least 6 bytes long. Return the number of UTF-8 bytes of data written.
|
609
|
+
*/
|
610
|
+
extern int
|
611
|
+
js_OneUcs4ToUtf8Char(uint8 *utf8Buffer, uint32 ucs4Char);
|
612
|
+
|
613
|
+
/*
|
614
|
+
* Write str into buffer escaping any non-printable or non-ASCII character.
|
615
|
+
* Guarantees that a NUL is at the end of the buffer. Returns the length of
|
616
|
+
* the written output, NOT including the NUL. If buffer is null, just returns
|
617
|
+
* the length of the output. If quote is not 0, it must be a single or double
|
618
|
+
* quote character that will quote the output.
|
619
|
+
*
|
620
|
+
* The function is only defined for debug builds.
|
621
|
+
*/
|
622
|
+
#define js_PutEscapedString(buffer, bufferSize, str, quote) \
|
623
|
+
js_PutEscapedStringImpl(buffer, bufferSize, NULL, str, quote)
|
624
|
+
|
625
|
+
/*
|
626
|
+
* Write str into file escaping any non-printable or non-ASCII character.
|
627
|
+
* Returns the number of bytes written to file. If quote is not 0, it must
|
628
|
+
* be a single or double quote character that will quote the output.
|
629
|
+
*
|
630
|
+
* The function is only defined for debug builds.
|
631
|
+
*/
|
632
|
+
#define js_FileEscapedString(file, str, quote) \
|
633
|
+
(JS_ASSERT(file), js_PutEscapedStringImpl(NULL, 0, file, str, quote))
|
634
|
+
|
635
|
+
extern JS_FRIEND_API(size_t)
|
636
|
+
js_PutEscapedStringImpl(char *buffer, size_t bufferSize, FILE *fp,
|
637
|
+
JSString *str, uint32 quote);
|
638
|
+
|
639
|
+
JS_END_EXTERN_C
|
640
|
+
|
641
|
+
#endif /* jsstr_h___ */
|