├── .cvsignore ├── .depend ├── Changes ├── INSTALL ├── LICENSE ├── Makefile ├── Makefile.nt ├── README ├── README.win32 ├── Upgrading ├── VERSION ├── _tags ├── asmcomp ├── .cvsignore ├── alpha │ ├── arch.ml │ ├── emit.mlp │ ├── proc.ml │ ├── reload.ml │ ├── scheduling.ml │ └── selection.ml ├── amd64 │ ├── arch.ml │ ├── emit.mlp │ ├── emit_nt.mlp │ ├── proc.ml │ ├── proc_nt.ml │ ├── reload.ml │ ├── scheduling.ml │ └── selection.ml ├── arm │ ├── arch.ml │ ├── emit.mlp │ ├── proc.ml │ ├── reload.ml │ ├── scheduling.ml │ └── selection.ml ├── asmgen.ml ├── asmgen.mli ├── asmlibrarian.ml ├── asmlibrarian.mli ├── asmlink.ml ├── asmlink.mli ├── asmpackager.ml ├── asmpackager.mli ├── clambda.ml ├── clambda.mli ├── closure.ml ├── closure.mli ├── cmm.ml ├── cmm.mli ├── cmmgen.ml ├── cmmgen.mli ├── cmx_format.mli ├── codegen.ml ├── codegen.mli ├── coloring.ml ├── coloring.mli ├── comballoc.ml ├── comballoc.mli ├── compilenv.ml ├── compilenv.mli ├── debuginfo.ml ├── debuginfo.mli ├── emit.mli ├── emitaux.ml ├── emitaux.mli ├── hppa │ ├── arch.ml │ ├── emit.mlp │ ├── proc.ml │ ├── reload.ml │ ├── scheduling.ml │ └── selection.ml ├── i386 │ ├── arch.ml │ ├── emit.mlp │ ├── emit_nt.mlp │ ├── proc.ml │ ├── proc_nt.ml │ ├── reload.ml │ ├── scheduling.ml │ └── selection.ml ├── ia64 │ ├── arch.ml │ ├── emit.mlp │ ├── proc.ml │ ├── reload.ml │ ├── scheduling.ml │ └── selection.ml ├── interf.ml ├── interf.mli ├── linearize.ml ├── linearize.mli ├── liveness.ml ├── liveness.mli ├── llvmcompile.ml ├── llvmcompile.mli ├── llvmemit.ml ├── llvmemit.mli ├── m68k │ └── README ├── mach.ml ├── mach.mli ├── mips │ ├── arch.ml │ ├── emit.mlp │ ├── proc.ml │ ├── reload.ml │ ├── scheduling.ml │ └── selection.ml ├── power │ ├── arch.ml │ ├── emit.mlp │ ├── proc.ml │ ├── reload.ml │ ├── scheduling.ml │ └── selection.ml ├── printcmm.ml ├── printcmm.mli ├── printlinear.ml ├── printlinear.mli ├── printmach.ml ├── printmach.mli ├── proc.mli ├── reg.ml ├── reg.mli ├── reload.mli ├── reloadgen.ml ├── reloadgen.mli ├── schedgen.ml ├── schedgen.mli ├── scheduling.mli ├── selectgen.ml ├── selectgen.mli ├── selection.mli ├── sparc │ ├── arch.ml │ ├── emit.mlp │ ├── proc.ml │ ├── reload.ml │ ├── scheduling.ml │ └── selection.ml ├── spill.ml ├── spill.mli ├── split.ml └── split.mli ├── asmrun ├── .cvsignore ├── .depend ├── Makefile ├── Makefile.nt ├── alpha.S ├── amd64.S ├── amd64nt.asm ├── arm.S ├── backtrace.c ├── fail.c ├── hppa.S ├── i386.S ├── i386nt.asm ├── ia64.S ├── m68k.S ├── mips.s ├── natdynlink.c ├── natdynlink.h ├── power-aix.S ├── power-elf.S ├── power-rhapsody.S ├── roots.c ├── signals_asm.c ├── signals_osdep.h ├── sparc.S ├── stack.h └── startup.c ├── boot ├── .cvsignore ├── myocamlbuild.boot ├── ocamlc ├── ocamldep └── ocamllex ├── build ├── .cvsignore ├── boot-c-parts.sh ├── boot.sh ├── buildbot ├── camlp4-bootstrap-recipe.txt ├── camlp4-bootstrap.sh ├── camlp4-byte-only.sh ├── camlp4-mkCamlp4Ast.sh ├── camlp4-native-only.sh ├── camlp4-targets.sh ├── distclean.sh ├── fastworld.sh ├── install.sh ├── mixed-boot.sh ├── mkconfig.sh ├── mkmyocamlbuild_config.sh ├── mkruntimedef.sh ├── myocamlbuild.sh ├── new-build-system ├── ocamlbuild-byte-only.sh ├── ocamlbuild-native-only.sh ├── ocamlbuildlib-native-only.sh ├── otherlibs-targets.sh ├── partial-install.sh ├── targets.sh ├── tolower.sed ├── world.all.sh ├── world.byte.sh ├── world.native.sh └── world.sh ├── bytecomp ├── .cvsignore ├── bytegen.ml ├── bytegen.mli ├── bytelibrarian.ml ├── bytelibrarian.mli ├── bytelink.ml ├── bytelink.mli ├── bytepackager.ml ├── bytepackager.mli ├── bytesections.ml ├── bytesections.mli ├── cmo_format.mli ├── dll.ml ├── dll.mli ├── emitcode.ml ├── emitcode.mli ├── instruct.ml ├── instruct.mli ├── lambda.ml ├── lambda.mli ├── matching.ml ├── matching.mli ├── meta.ml ├── meta.mli ├── printinstr.ml ├── printinstr.mli ├── printlambda.ml ├── printlambda.mli ├── runtimedef.mli ├── simplif.ml ├── simplif.mli ├── switch.ml ├── switch.mli ├── symtable.ml ├── symtable.mli ├── translclass.ml ├── translclass.mli ├── translcore.ml ├── translcore.mli ├── translmod.ml ├── translmod.mli ├── translobj.ml ├── translobj.mli ├── typeopt.ml └── typeopt.mli ├── byterun ├── .cvsignore ├── .depend ├── Makefile ├── Makefile.common ├── Makefile.nt ├── alloc.c ├── alloc.h ├── array.c ├── backtrace.c ├── backtrace.h ├── callback.c ├── callback.h ├── compact.c ├── compact.h ├── compare.c ├── compare.h ├── compatibility.h ├── config.h ├── custom.c ├── custom.h ├── debugger.c ├── debugger.h ├── dynlink.c ├── dynlink.h ├── exec.h ├── extern.c ├── fail.c ├── fail.h ├── finalise.c ├── finalise.h ├── fix_code.c ├── fix_code.h ├── floats.c ├── freelist.c ├── freelist.h ├── gc.h ├── gc_ctrl.c ├── gc_ctrl.h ├── globroots.c ├── globroots.h ├── hash.c ├── instrtrace.c ├── instrtrace.h ├── instruct.h ├── int64_emul.h ├── int64_format.h ├── int64_native.h ├── intern.c ├── interp.c ├── interp.h ├── intext.h ├── ints.c ├── io.c ├── io.h ├── lexing.c ├── main.c ├── major_gc.c ├── major_gc.h ├── md5.c ├── md5.h ├── memory.c ├── memory.h ├── meta.c ├── minor_gc.c ├── minor_gc.h ├── misc.c ├── misc.h ├── mlvalues.h ├── obj.c ├── osdeps.h ├── parsing.c ├── prims.h ├── printexc.c ├── printexc.h ├── reverse.h ├── roots.c ├── roots.h ├── signals.c ├── signals.h ├── signals_byt.c ├── signals_machdep.h ├── stacks.c ├── stacks.h ├── startup.c ├── startup.h ├── str.c ├── sys.c ├── sys.h ├── terminfo.c ├── ui.h ├── unix.c ├── weak.c ├── weak.h └── win32.c ├── camlp4 ├── .cvsignore ├── CHANGES ├── Camlp4.mlpack ├── Camlp4 │ ├── .cvsignore │ ├── Camlp4Ast.partial.ml │ ├── Debug.ml │ ├── Debug.mli │ ├── ErrorHandler.ml │ ├── ErrorHandler.mli │ ├── OCamlInitSyntax.ml │ ├── Options.ml │ ├── Options.mli │ ├── PreCast.ml │ ├── PreCast.mli │ ├── Printers.mlpack │ ├── Printers │ │ ├── DumpCamlp4Ast.ml │ │ ├── DumpCamlp4Ast.mli │ │ ├── DumpOCamlAst.ml │ │ ├── DumpOCamlAst.mli │ │ ├── Null.ml │ │ ├── Null.mli │ │ ├── OCaml.ml │ │ ├── OCaml.mli │ │ ├── OCamlr.ml │ │ └── OCamlr.mli │ ├── Register.ml │ ├── Register.mli │ ├── Sig.ml │ ├── Struct.mlpack │ └── Struct │ │ ├── .cvsignore │ │ ├── AstFilters.ml │ │ ├── Camlp4Ast.mlast │ │ ├── Camlp4Ast2OCamlAst.ml │ │ ├── Camlp4Ast2OCamlAst.mli │ │ ├── CleanAst.ml │ │ ├── CommentFilter.ml │ │ ├── CommentFilter.mli │ │ ├── DynAst.ml │ │ ├── DynLoader.ml │ │ ├── DynLoader.mli │ │ ├── EmptyError.ml │ │ ├── EmptyError.mli │ │ ├── EmptyPrinter.ml │ │ ├── EmptyPrinter.mli │ │ ├── FreeVars.ml │ │ ├── FreeVars.mli │ │ ├── Grammar.mlpack │ │ ├── Grammar │ │ ├── Delete.ml │ │ ├── Dynamic.ml │ │ ├── Entry.ml │ │ ├── Failed.ml │ │ ├── Find.ml │ │ ├── Fold.ml │ │ ├── Fold.mli │ │ ├── Insert.ml │ │ ├── Parser.ml │ │ ├── Parser.mli │ │ ├── Print.ml │ │ ├── Print.mli │ │ ├── Search.ml │ │ ├── Static.ml │ │ ├── Structure.ml │ │ └── Tools.ml │ │ ├── Lexer.mll │ │ ├── Loc.ml │ │ ├── Loc.mli │ │ ├── Quotation.ml │ │ ├── Token.ml │ │ └── Token.mli ├── Camlp4Bin.ml ├── Camlp4Filters │ ├── Camlp4AstLifter.ml │ ├── Camlp4ExceptionTracer.ml │ ├── Camlp4FoldGenerator.ml │ ├── Camlp4LocationStripper.ml │ ├── Camlp4MapGenerator.ml │ ├── Camlp4MetaGenerator.ml │ ├── Camlp4Profiler.ml │ └── Camlp4TrashRemover.ml ├── Camlp4Parsers │ ├── Camlp4AstLoader.ml │ ├── Camlp4DebugParser.ml │ ├── Camlp4GrammarParser.ml │ ├── Camlp4ListComprehension.ml │ ├── Camlp4MacroParser.ml │ ├── Camlp4OCamlOriginalQuotationExpander.ml │ ├── Camlp4OCamlParser.ml │ ├── Camlp4OCamlParserParser.ml │ ├── Camlp4OCamlReloadedParser.ml │ ├── Camlp4OCamlRevisedParser.ml │ ├── Camlp4OCamlRevisedParserParser.ml │ ├── Camlp4OCamlRevisedQuotationExpander.ml │ ├── Camlp4QuotationCommon.ml │ └── Camlp4QuotationExpander.ml ├── Camlp4Printers │ ├── Camlp4AstDumper.ml │ ├── Camlp4AutoPrinter.ml │ ├── Camlp4NullDumper.ml │ ├── Camlp4OCamlAstDumper.ml │ ├── Camlp4OCamlPrinter.ml │ └── Camlp4OCamlRevisedPrinter.ml ├── Camlp4Top.mlpack ├── Camlp4Top │ ├── Rprint.ml │ └── Top.ml ├── Camlp4_config.ml ├── Camlp4_config.mli ├── ICHANGES ├── boot │ ├── .cvsignore │ ├── Camlp4.ml │ ├── Camlp4.ml4 │ ├── Camlp4Ast.ml │ ├── camlp4boot.ml │ └── camlp4boot.ml4 ├── build │ └── .cvsignore ├── camlp4.odocl ├── camlp4fulllib.mllib ├── camlp4lib.mllib ├── camlp4prof.ml ├── camlp4prof.mli ├── examples │ ├── _tags │ ├── all.itarget │ ├── apply_operator.ml │ ├── apply_operator_test.ml │ ├── arith.ml │ ├── debug_extension.ml │ ├── ex_str.ml │ ├── ex_str_test.ml │ ├── expression_closure.ml │ ├── expression_closure_filter.ml │ ├── expression_closure_test.ml │ ├── fancy_lambda_quot.ml │ ├── fancy_lambda_quot_test.ml │ ├── free_vars_test.ml │ ├── gen_match_case.ml │ ├── gen_type_N.ml │ ├── gettext_test.ml │ ├── global_handler.ml │ ├── global_handler_test.ml │ ├── lambda_parser.ml │ ├── lambda_quot.ml │ ├── lambda_quot_expr.ml │ ├── lambda_quot_patt.ml │ ├── lambda_test.ml │ ├── macros.ml │ ├── parse_files.ml │ ├── syb_fold.ml │ ├── syb_map.ml │ ├── test.itarget │ ├── test_macros.ml │ ├── test_type_quotation.ml │ └── type_quotation.ml ├── man │ ├── .cvsignore │ ├── Makefile │ └── camlp4.1.tpl ├── mkcamlp4.ml ├── test │ └── fixtures │ │ ├── assert.ml │ │ ├── backquoted_irrefutable_tuple.ml │ │ ├── backquoted_record.ml │ │ ├── backquoted_tuple.ml │ │ ├── big-tab1.ml │ │ ├── big-tab2.ml │ │ ├── big-tab3.ml │ │ ├── bug-4058.ml │ │ ├── bug-4337.ml │ │ ├── bug-by-vincent-balat.ml │ │ ├── bug-camlp4o-benjamin-monate.ml │ │ ├── bug-camlp4o-constr-arity-expr.ml │ │ ├── bug-camlp4o-constr-arity.ml │ │ ├── bug_escaping_quot.ml │ │ ├── chars.ml │ │ ├── class_expr_quot.ml │ │ ├── comments.ml │ │ ├── comments.mli │ │ ├── comments2.ml │ │ ├── constant-parser.ml │ │ ├── curry-constr.ml │ │ ├── default_quotation.ml │ │ ├── exception-with-eqn-bug.ml │ │ ├── external.ml │ │ ├── fun.ml │ │ ├── functor-perf.ml │ │ ├── functor-perf2.gen.ml │ │ ├── functor-perf2.ml │ │ ├── functor-perf3.ml │ │ ├── gen_map.ml │ │ ├── gram-fold.ml │ │ ├── gram-list.ml │ │ ├── gram-loc-lost.ml │ │ ├── gram-sub-rule.ml │ │ ├── gram-tree.ml │ │ ├── gram-tree2.ml │ │ ├── gram-tree3.ml │ │ ├── gram.ml │ │ ├── idents │ │ ├── idents1 │ │ ├── idents2 │ │ ├── if.ml │ │ ├── label.ml │ │ ├── lambda_free.ml │ │ ├── loc-bug.ml │ │ ├── macrotest.ml │ │ ├── macrotest.mli │ │ ├── macrotest2.ml │ │ ├── macrotest3.ml │ │ ├── make_extend.ml │ │ ├── match.ml │ │ ├── match_parser.ml │ │ ├── meta_multi_term.ml │ │ ├── metalib.ml │ │ ├── method_private_virtual.ml │ │ ├── mod.ml │ │ ├── mod2.ml │ │ ├── operators.ml │ │ ├── operators.mli │ │ ├── original_syntax.ml │ │ ├── outside-scope.ml │ │ ├── parser.ml │ │ ├── pp_let_in.ml │ │ ├── pp_let_in2.ml │ │ ├── pp_xml.ml │ │ ├── pprecordtyp.ml │ │ ├── pr4314.ml │ │ ├── pr4314gram1.ml │ │ ├── pr4314gram2.ml │ │ ├── pr4314gram3.ml │ │ ├── pr4314gram4.ml │ │ ├── pr4314gram5.ml │ │ ├── pr4329.ml │ │ ├── pr4330.ml │ │ ├── pr4357.ml │ │ ├── pr4357sample.ml │ │ ├── pr4357sample2.ml │ │ ├── pr4452.ml │ │ ├── private_row.ml │ │ ├── rec.ml │ │ ├── seq.ml │ │ ├── seq2.ml │ │ ├── simplify.ml │ │ ├── simplify_r.ml │ │ ├── stream-parser-bug.ml │ │ ├── string.ml │ │ ├── superfluous.ml │ │ ├── transform-examples.ml │ │ ├── try.ml │ │ ├── tuple_as_retval.ml │ │ ├── type.ml │ │ ├── type_decl.ml │ │ ├── unit.ml │ │ ├── use.ml │ │ ├── where.o.ml │ │ └── where.r.ml └── unmaintained │ ├── Makefile │ ├── compile │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── comp_head.ml │ ├── comp_trail.ml │ ├── compile.ml │ └── compile.sh │ ├── etc │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── pa_fstream.ml │ ├── pa_ifdef.ml │ ├── pa_oop.ml │ ├── pa_ru.ml │ ├── parserify.ml │ ├── parserify.mli │ ├── pr_depend.ml │ ├── pr_extend.ml │ ├── pr_extfun.ml │ ├── pr_null.ml │ ├── pr_op.ml │ ├── pr_op_main.ml │ ├── pr_rp.ml │ ├── pr_rp_main.ml │ └── q_phony.ml │ ├── extfold │ ├── README │ └── pa_extfold.ml │ ├── format │ ├── .depend │ ├── Makefile │ ├── README │ └── pa_format.ml │ ├── lefteval │ ├── .depend │ ├── Makefile │ ├── README │ └── pa_lefteval.ml │ ├── lib │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── extfun.ml │ ├── extfun.mli │ ├── fstream.ml │ └── fstream.mli │ ├── ocamllex │ ├── Makefile │ ├── README │ └── pa_ocamllex.ml │ ├── ocpp │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ └── ocpp.ml │ ├── odyl │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── odyl.ml │ └── odyl_main.mli │ ├── olabl │ ├── .depend │ ├── Makefile │ ├── README │ └── pa_olabl.ml │ ├── scheme │ ├── .depend │ ├── Makefile │ ├── README │ ├── pa_scheme.ml │ ├── pa_scheme.sc │ ├── pr_scheme.ml │ └── pr_schp_main.ml │ └── sml │ ├── .depend │ ├── Makefile │ ├── README │ ├── pa_sml.ml │ └── smllib.sml ├── config ├── .cvsignore ├── Makefile-templ ├── Makefile.mingw ├── Makefile.msvc ├── Makefile.msvc64 ├── auto-aux │ ├── .cvsignore │ ├── align.c │ ├── ansi.c │ ├── async_io.c │ ├── bytecopy.c │ ├── dblalign.c │ ├── divmod.c │ ├── elf.c │ ├── endian.c │ ├── expm1.c │ ├── getgroups.c │ ├── gethostbyaddr.c │ ├── gethostbyname.c │ ├── hasgot │ ├── ia32sse2.c │ ├── initgroups.c │ ├── int64align.c │ ├── longlong.c │ ├── runtest │ ├── schar.c │ ├── schar2.c │ ├── searchpath │ ├── setgroups.c │ ├── sharpbang │ ├── sharpbang2 │ ├── sighandler.c │ ├── signals.c │ ├── sizes.c │ ├── solaris-ld │ ├── stackov.c │ ├── tclversion.c │ └── trycompile ├── gnu │ ├── config.guess │ └── config.sub ├── m-nt.h ├── m-templ.h ├── s-nt.h └── s-templ.h ├── configure ├── debugger ├── .cvsignore ├── .depend ├── Makefile ├── Makefile.nt ├── Makefile.shared ├── breakpoints.ml ├── breakpoints.mli ├── checkpoints.ml ├── checkpoints.mli ├── command_line.ml ├── command_line.mli ├── debugcom.ml ├── debugcom.mli ├── debugger_config.ml ├── debugger_config.mli ├── envaux.ml ├── envaux.mli ├── eval.ml ├── eval.mli ├── events.ml ├── events.mli ├── exec.ml ├── exec.mli ├── frames.ml ├── frames.mli ├── history.ml ├── history.mli ├── input_handling.ml ├── input_handling.mli ├── int64ops.ml ├── int64ops.mli ├── lexer.mli ├── lexer.mll ├── loadprinter.ml ├── loadprinter.mli ├── main.ml ├── parameters.ml ├── parameters.mli ├── parser.mly ├── parser_aux.mli ├── pattern_matching.ml ├── pattern_matching.mli ├── pos.ml ├── pos.mli ├── primitives.ml ├── primitives.mli ├── printval.ml ├── printval.mli ├── program_loading.ml ├── program_loading.mli ├── program_management.ml ├── program_management.mli ├── question.ml ├── question.mli ├── show_information.ml ├── show_information.mli ├── show_source.ml ├── show_source.mli ├── source.ml ├── source.mli ├── symbols.ml ├── symbols.mli ├── time_travel.ml ├── time_travel.mli ├── trap_barrier.ml ├── trap_barrier.mli ├── unix_tools.ml └── unix_tools.mli ├── driver ├── compile.ml ├── compile.mli ├── errors.ml ├── errors.mli ├── main.ml ├── main.mli ├── main_args.ml ├── main_args.mli ├── ocamlcomp.sh.in ├── optcompile.ml ├── optcompile.mli ├── opterrors.ml ├── opterrors.mli ├── optmain.ml ├── optmain.mli ├── pparse.ml └── pparse.mli ├── emacs ├── .cvsignore ├── COPYING ├── Makefile ├── README ├── README.itz ├── caml-compat.el ├── caml-emacs.el ├── caml-font-old.el ├── caml-font.el ├── caml-help.el ├── caml-hilit.el ├── caml-types.el ├── caml-xemacs.el ├── caml.el ├── camldebug.el ├── inf-caml.el └── ocamltags.in ├── lex ├── .cvsignore ├── .depend ├── Makefile ├── Makefile.nt ├── common.ml ├── common.mli ├── compact.ml ├── compact.mli ├── cset.ml ├── cset.mli ├── lexer.mli ├── lexer.mll ├── lexgen.ml ├── lexgen.mli ├── main.ml ├── output.ml ├── output.mli ├── outputbis.ml ├── outputbis.mli ├── parser.mly ├── syntax.ml ├── syntax.mli ├── table.ml └── table.mli ├── man ├── Makefile ├── ocaml.m ├── ocamlc.m ├── ocamlcp.m ├── ocamldebug.m ├── ocamldep.m ├── ocamldoc.m ├── ocamllex.m ├── ocamlmktop.m ├── ocamlopt.m ├── ocamlprof.m ├── ocamlrun.m └── ocamlyacc.m ├── myocamlbuild.ml ├── myocamlbuild_config.mli ├── ocamlbuild ├── AUTHORS ├── ChangeLog ├── FAQ ├── Makefile ├── TODO ├── _tags ├── bool.ml ├── bool.mli ├── command.ml ├── command.mli ├── configuration.ml ├── configuration.mli ├── digest_cache.ml ├── digest_cache.mli ├── discard_printf.ml ├── discard_printf.mli ├── display.ml ├── display.mli ├── examples │ ├── example1 │ │ └── hello.ml │ ├── example2 │ │ ├── greet.ml │ │ └── hello.ml │ └── example3 │ │ ├── epoch.ml │ │ └── make.sh ├── exit_codes.ml ├── exit_codes.mli ├── fda.ml ├── fda.mli ├── findlib.ml ├── findlib.mli ├── flags.ml ├── flags.mli ├── glob.ml ├── glob.mli ├── glob_ast.ml ├── glob_ast.mli ├── glob_lexer.mli ├── glob_lexer.mll ├── hooks.ml ├── hooks.mli ├── hygiene.ml ├── hygiene.mli ├── lexers.mli ├── lexers.mll ├── log.ml ├── log.mli ├── main.ml ├── main.mli ├── man │ └── ocamlbuild.1 ├── manual │ ├── .cvsignore │ ├── Makefile │ ├── manual.hva │ ├── manual.tex │ ├── myocamlbuild.ml │ └── trace.out ├── misc │ └── opentracer.ml ├── my_std.ml ├── my_std.mli ├── my_unix.ml ├── my_unix.mli ├── ocaml_arch.ml ├── ocaml_arch.mli ├── ocaml_compiler.ml ├── ocaml_compiler.mli ├── ocaml_dependencies.ml ├── ocaml_dependencies.mli ├── ocaml_specific.ml ├── ocaml_specific.mli ├── ocaml_tools.ml ├── ocaml_tools.mli ├── ocaml_utils.ml ├── ocaml_utils.mli ├── ocamlbuild-presentation.rslide ├── ocamlbuild.ml ├── ocamlbuild.mli ├── ocamlbuild.mltop ├── ocamlbuild.odocl ├── ocamlbuild_executor.ml ├── ocamlbuild_executor.mli ├── ocamlbuild_pack.mlpack ├── ocamlbuild_plugin.ml ├── ocamlbuild_plugin.mli ├── ocamlbuild_unix_plugin.ml ├── ocamlbuild_unix_plugin.mli ├── ocamlbuild_where.ml ├── ocamlbuild_where.mli ├── ocamlbuildlib.mllib ├── ocamlbuildlight.ml ├── ocamlbuildlight.mli ├── ocamlbuildlightlib.mllib ├── options.ml ├── options.mli ├── param_tags.ml ├── param_tags.mli ├── pathname.ml ├── pathname.mli ├── plugin.ml ├── plugin.mli ├── ppcache.ml ├── ppcache.mli ├── report.ml ├── report.mli ├── resource.ml ├── resource.mli ├── rule.ml ├── rule.mli ├── shell.ml ├── shell.mli ├── signatures.mli ├── slurp.ml ├── slurp.mli ├── solver.ml ├── solver.mli ├── start.sh ├── tags.ml ├── tags.mli ├── test │ ├── good-output │ ├── runtest.sh │ ├── test1 │ │ └── foo.ml │ ├── test10 │ │ ├── dbdi │ │ └── test.sh │ ├── test11 │ │ ├── _tags │ │ ├── a │ │ │ ├── aa.ml │ │ │ └── aa.mli │ │ ├── b │ │ │ ├── bb.ml │ │ │ └── libb.mllib │ │ ├── myocamlbuild.ml │ │ └── test.sh │ ├── test2 │ │ ├── _tags │ │ ├── tata.ml │ │ ├── tata.mli │ │ ├── test.sh │ │ ├── titi.ml │ │ ├── toto.ml │ │ ├── tutu.ml │ │ ├── tutu.mli │ │ ├── tyty.mli │ │ ├── vivi1.ml │ │ ├── vivi2.ml │ │ └── vivi3.ml │ ├── test3 │ │ ├── _tags │ │ ├── a.ml │ │ ├── a.mli │ │ ├── b.ml │ │ ├── b.mli │ │ ├── c.ml │ │ ├── c.mli │ │ ├── d.ml │ │ ├── d.mli │ │ ├── e.ml │ │ ├── e.mli │ │ ├── f.ml │ │ ├── f.mli │ │ ├── proj.odocl │ │ └── test.sh │ ├── test4 │ │ ├── _tags │ │ ├── a │ │ │ ├── aa.ml │ │ │ └── aa.mli │ │ ├── b │ │ │ └── bb.ml │ │ └── test.sh │ ├── test5 │ │ ├── _tags │ │ ├── a.ml │ │ ├── a.mli │ │ ├── b.ml │ │ ├── c.mlpack │ │ ├── d.ml │ │ ├── stack.ml │ │ └── test.sh │ ├── test6 │ │ ├── a.ml │ │ ├── a.mli │ │ ├── b.ml │ │ ├── b.mli │ │ ├── b.mli.v1 │ │ ├── b.mli.v2 │ │ ├── d.ml │ │ ├── d.mli │ │ ├── d.mli.v1 │ │ ├── d.mli.v2 │ │ ├── main.ml │ │ ├── main.mli │ │ └── test.sh │ ├── test7 │ │ ├── _tags │ │ ├── aa.ml │ │ ├── bb.mli │ │ ├── bb1.ml │ │ ├── bb2.ml │ │ ├── bb3.ml │ │ ├── bbcc.mllib │ │ ├── c2.ml │ │ ├── c2.mli │ │ ├── c3.ml │ │ ├── cc.ml │ │ ├── cool_plugin.ml │ │ ├── main.ml │ │ ├── myocamlbuild.ml │ │ └── test.sh │ ├── test8 │ │ ├── a.ml │ │ ├── myocamlbuild.ml │ │ └── test.sh │ ├── test9 │ │ ├── dbgl │ │ ├── test.sh │ │ └── testglob.ml │ └── test_virtual │ │ ├── foo.itarget │ │ ├── foo1 │ │ ├── foo2 │ │ ├── myocamlbuild.ml │ │ └── test.sh ├── tools.ml └── tools.mli ├── ocamldoc ├── .cvsignore ├── .depend ├── Changes.txt ├── Makefile ├── Makefile.nt ├── ocamldoc.hva ├── ocamldoc.sty ├── odoc.ml ├── odoc_analyse.ml ├── odoc_analyse.mli ├── odoc_args.ml ├── odoc_args.mli ├── odoc_ast.ml ├── odoc_ast.mli ├── odoc_class.ml ├── odoc_comments.ml ├── odoc_comments.mli ├── odoc_comments_global.ml ├── odoc_comments_global.mli ├── odoc_config.ml ├── odoc_config.mli ├── odoc_control.ml ├── odoc_cross.ml ├── odoc_cross.mli ├── odoc_dag2html.ml ├── odoc_dag2html.mli ├── odoc_dep.ml ├── odoc_dot.ml ├── odoc_env.ml ├── odoc_env.mli ├── odoc_exception.ml ├── odoc_global.ml ├── odoc_global.mli ├── odoc_html.ml ├── odoc_info.ml ├── odoc_info.mli ├── odoc_inherit.ml ├── odoc_latex.ml ├── odoc_latex_style.ml ├── odoc_lexer.mll ├── odoc_man.ml ├── odoc_merge.ml ├── odoc_merge.mli ├── odoc_messages.ml ├── odoc_misc.ml ├── odoc_misc.mli ├── odoc_module.ml ├── odoc_name.ml ├── odoc_name.mli ├── odoc_ocamlhtml.mll ├── odoc_parameter.ml ├── odoc_parser.mly ├── odoc_print.ml ├── odoc_print.mli ├── odoc_scan.ml ├── odoc_search.ml ├── odoc_search.mli ├── odoc_see_lexer.mll ├── odoc_sig.ml ├── odoc_sig.mli ├── odoc_str.ml ├── odoc_str.mli ├── odoc_test.ml ├── odoc_texi.ml ├── odoc_text.ml ├── odoc_text.mli ├── odoc_text_lexer.mll ├── odoc_text_parser.mly ├── odoc_to_text.ml ├── odoc_type.ml ├── odoc_types.ml ├── odoc_types.mli ├── odoc_value.ml ├── remove_DEBUG └── runocamldoc ├── otherlibs ├── Makefile ├── Makefile.nt ├── Makefile.shared ├── bigarray │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── Makefile.nt │ ├── bigarray.h │ ├── bigarray.ml │ ├── bigarray.mli │ ├── bigarray_stubs.c │ ├── libbigarray.clib │ ├── libbigarraywin32.clib │ ├── mmap_unix.c │ └── mmap_win32.c ├── dbm │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── cldbm.c │ ├── dbm.ml │ ├── dbm.mli │ └── libmldbm.clib ├── dynlink │ ├── .cvsignore │ ├── Makefile │ ├── Makefile.nt │ ├── dynlink.ml │ ├── dynlink.mli │ ├── dynlinkaux.mlpack │ ├── extract_crc.ml │ └── natdynlink.ml ├── graph │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── color.c │ ├── draw.c │ ├── dump_img.c │ ├── events.c │ ├── fill.c │ ├── graphics.ml │ ├── graphics.mli │ ├── graphics.mllib │ ├── graphicsX11.ml │ ├── graphicsX11.mli │ ├── image.c │ ├── image.h │ ├── libgraph.h │ ├── libgraphics.clib │ ├── make_img.c │ ├── open.c │ ├── point_col.c │ ├── sound.c │ ├── subwindow.c │ └── text.c ├── labltk │ ├── .cvsignore │ ├── Changes │ ├── Makefile │ ├── Makefile.nt │ ├── README │ ├── Widgets.src │ ├── browser │ │ ├── .cvsignore │ │ ├── .depend │ │ ├── Makefile │ │ ├── Makefile.nt │ │ ├── Makefile.shared │ │ ├── README │ │ ├── dummyUnix.mli │ │ ├── dummyWin.mli │ │ ├── editor.ml │ │ ├── editor.mli │ │ ├── fileselect.ml │ │ ├── fileselect.mli │ │ ├── help.ml │ │ ├── help.txt │ │ ├── jg_bind.ml │ │ ├── jg_bind.mli │ │ ├── jg_box.ml │ │ ├── jg_button.ml │ │ ├── jg_completion.ml │ │ ├── jg_completion.mli │ │ ├── jg_config.ml │ │ ├── jg_config.mli │ │ ├── jg_entry.ml │ │ ├── jg_memo.ml │ │ ├── jg_memo.mli │ │ ├── jg_menu.ml │ │ ├── jg_message.ml │ │ ├── jg_message.mli │ │ ├── jg_multibox.ml │ │ ├── jg_multibox.mli │ │ ├── jg_text.ml │ │ ├── jg_text.mli │ │ ├── jg_tk.ml │ │ ├── jg_toplevel.ml │ │ ├── jglib.mllib │ │ ├── lexical.ml │ │ ├── lexical.mli │ │ ├── list2.ml │ │ ├── main.ml │ │ ├── mytypes.mli │ │ ├── searchid.ml │ │ ├── searchid.mli │ │ ├── searchpos.ml │ │ ├── searchpos.mli │ │ ├── setpath.ml │ │ ├── setpath.mli │ │ ├── shell.ml │ │ ├── shell.mli │ │ ├── typecheck.ml │ │ ├── typecheck.mli │ │ ├── useunix.ml │ │ ├── useunix.mli │ │ ├── viewer.ml │ │ ├── viewer.mli │ │ └── winmain.c │ ├── builtin │ │ ├── LICENSE │ │ ├── builtin_FilePattern.ml │ │ ├── builtin_GetBitmap.ml │ │ ├── builtin_GetCursor.ml │ │ ├── builtin_GetPixel.ml │ │ ├── builtin_ScrollValue.ml │ │ ├── builtin_bind.ml │ │ ├── builtin_bindtags.ml │ │ ├── builtin_font.ml │ │ ├── builtin_grab.ml │ │ ├── builtin_index.ml │ │ ├── builtin_palette.ml │ │ ├── builtin_text.ml │ │ ├── builtina_empty.ml │ │ ├── builtinf_GetPixel.ml │ │ ├── builtinf_bind.ml │ │ ├── builtini_GetBitmap.ml │ │ ├── builtini_GetCursor.ml │ │ ├── builtini_GetPixel.ml │ │ ├── builtini_ScrollValue.ml │ │ ├── builtini_bind.ml │ │ ├── builtini_bindtags.ml │ │ ├── builtini_font.ml │ │ ├── builtini_grab.ml │ │ ├── builtini_index.ml │ │ ├── builtini_palette.ml │ │ ├── builtini_text.ml │ │ ├── canvas_bind.ml │ │ ├── canvas_bind.mli │ │ ├── dialog.ml │ │ ├── dialog.mli │ │ ├── image.ml │ │ ├── image.mli │ │ ├── optionmenu.ml │ │ ├── optionmenu.mli │ │ ├── rawimg.ml │ │ ├── rawimg.mli │ │ ├── report.ml │ │ ├── selection_handle_set.ml │ │ ├── selection_handle_set.mli │ │ ├── selection_own_set.ml │ │ ├── selection_own_set.mli │ │ ├── text_tag_bind.ml │ │ ├── text_tag_bind.mli │ │ ├── winfo_contained.ml │ │ └── winfo_contained.mli │ ├── camltk │ │ ├── .cvsignore │ │ ├── Makefile │ │ ├── Makefile.gen │ │ ├── Makefile.gen.nt │ │ ├── Makefile.nt │ │ ├── byte.itarget │ │ ├── modules │ │ └── native.itarget │ ├── compiler │ │ ├── .cvsignore │ │ ├── .depend │ │ ├── Makefile │ │ ├── Makefile.nt │ │ ├── code.mli │ │ ├── compile.ml │ │ ├── copyright │ │ ├── flags.ml │ │ ├── intf.ml │ │ ├── lexer.mll │ │ ├── maincompile.ml │ │ ├── parser.mly │ │ ├── pp.ml │ │ ├── ppexec.ml │ │ ├── pplex.mli │ │ ├── pplex.mll │ │ ├── ppparse.ml │ │ ├── ppyac.mly │ │ ├── printer.ml │ │ ├── tables.ml │ │ └── tsort.ml │ ├── examples_camltk │ │ ├── .cvsignore │ │ ├── Makefile │ │ ├── Makefile.nt │ │ ├── addition.ml │ │ ├── eyes.ml │ │ ├── fileinput.ml │ │ ├── fileopen.ml │ │ ├── helloworld.ml │ │ ├── images │ │ │ ├── CamlBook.gif │ │ │ ├── Lambda2.back.gif │ │ │ └── dojoji.back.gif │ │ ├── jptest.ml │ │ ├── mytext.ml │ │ ├── socketinput.ml │ │ ├── taddition.ml │ │ ├── tetris.ml │ │ ├── text.ml │ │ └── winskel.ml │ ├── examples_labltk │ │ ├── .cvsignore │ │ ├── Lambda2.back.gif │ │ ├── Makefile │ │ ├── Makefile.nt │ │ ├── README │ │ ├── calc.ml │ │ ├── clock.ml │ │ ├── demo.ml │ │ ├── eyes.ml │ │ ├── hello.ml │ │ ├── hello.tcl │ │ ├── lang.ml │ │ ├── taquin.ml │ │ └── tetris.ml │ ├── frx │ │ ├── .cvsignore │ │ ├── .depend │ │ ├── Makefile │ │ ├── Makefile.nt │ │ ├── README │ │ ├── frx_after.ml │ │ ├── frx_after.mli │ │ ├── frx_color.ml │ │ ├── frx_color.mli │ │ ├── frx_ctext.ml │ │ ├── frx_ctext.mli │ │ ├── frx_dialog.ml │ │ ├── frx_dialog.mli │ │ ├── frx_entry.ml │ │ ├── frx_entry.mli │ │ ├── frx_fileinput.ml │ │ ├── frx_fillbox.ml │ │ ├── frx_fillbox.mli │ │ ├── frx_fit.ml │ │ ├── frx_fit.mli │ │ ├── frx_focus.ml │ │ ├── frx_focus.mli │ │ ├── frx_font.ml │ │ ├── frx_font.mli │ │ ├── frx_group.ml │ │ ├── frx_lbutton.ml │ │ ├── frx_lbutton.mli │ │ ├── frx_listbox.ml │ │ ├── frx_listbox.mli │ │ ├── frx_mem.ml │ │ ├── frx_mem.mli │ │ ├── frx_misc.ml │ │ ├── frx_misc.mli │ │ ├── frx_req.ml │ │ ├── frx_req.mli │ │ ├── frx_rpc.ml │ │ ├── frx_rpc.mli │ │ ├── frx_selection.ml │ │ ├── frx_selection.mli │ │ ├── frx_synth.ml │ │ ├── frx_synth.mli │ │ ├── frx_text.ml │ │ ├── frx_text.mli │ │ ├── frx_toplevel.mli │ │ ├── frx_widget.ml │ │ ├── frx_widget.mli │ │ └── frxlib.mllib │ ├── jpf │ │ ├── .cvsignore │ │ ├── Makefile │ │ ├── Makefile.nt │ │ ├── README │ │ ├── balloon.ml │ │ ├── balloon.mli │ │ ├── balloontest.ml │ │ ├── fileselect.ml │ │ ├── fileselect.mli │ │ ├── jpf_font.ml │ │ ├── jpf_font.mli │ │ ├── jpflib.mllib │ │ ├── shell.ml │ │ └── shell.mli │ ├── labl.gif │ ├── labltk │ │ ├── .cvsignore │ │ ├── Makefile │ │ ├── Makefile.gen │ │ ├── Makefile.gen.nt │ │ ├── Makefile.nt │ │ ├── byte.itarget │ │ ├── modules │ │ └── native.itarget │ ├── lib │ │ ├── .cvsignore │ │ ├── Makefile │ │ ├── Makefile.nt │ │ └── labltk.bat │ └── support │ │ ├── .cvsignore │ │ ├── .depend │ │ ├── Makefile │ │ ├── Makefile.common │ │ ├── Makefile.nt │ │ ├── byte.itarget │ │ ├── camltk.h │ │ ├── camltkwrap.ml │ │ ├── camltkwrap.mli │ │ ├── cltkCaml.c │ │ ├── cltkDMain.c │ │ ├── cltkEval.c │ │ ├── cltkEvent.c │ │ ├── cltkFile.c │ │ ├── cltkImg.c │ │ ├── cltkMain.c │ │ ├── cltkMisc.c │ │ ├── cltkTimer.c │ │ ├── cltkUtf.c │ │ ├── cltkVar.c │ │ ├── cltkWait.c │ │ ├── fileevent.ml │ │ ├── fileevent.mli │ │ ├── liblabltk.clib │ │ ├── native.itarget │ │ ├── protocol.ml │ │ ├── protocol.mli │ │ ├── rawwidget.ml │ │ ├── rawwidget.mli │ │ ├── slave.ml │ │ ├── support.ml │ │ ├── support.mli │ │ ├── textvariable.ml │ │ ├── textvariable.mli │ │ ├── timer.ml │ │ ├── timer.mli │ │ ├── tkthread.ml │ │ ├── tkthread.mli │ │ ├── tkwait.ml │ │ ├── widget.ml │ │ └── widget.mli ├── num │ ├── .cvsignore │ ├── .depend │ ├── .depend.nt │ ├── Makefile │ ├── Makefile.nt │ ├── README │ ├── arith_flags.ml │ ├── arith_flags.mli │ ├── arith_status.ml │ ├── arith_status.mli │ ├── big_int.ml │ ├── big_int.mli │ ├── bignum │ │ └── .cvsignore │ ├── bng.c │ ├── bng.h │ ├── bng_alpha.c │ ├── bng_amd64.c │ ├── bng_digit.c │ ├── bng_ia32.c │ ├── bng_mips.c │ ├── bng_ppc.c │ ├── bng_sparc.c │ ├── int_misc.ml │ ├── int_misc.mli │ ├── libnums.clib │ ├── nat.h │ ├── nat.ml │ ├── nat.mli │ ├── nat_stubs.c │ ├── num.ml │ ├── num.mli │ ├── nums.mllib │ ├── ratio.ml │ └── ratio.mli ├── str │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── Makefile.nt │ ├── libstr.clib │ ├── str.ml │ ├── str.mli │ └── strstubs.c ├── systhreads │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── Makefile.nt │ ├── condition.ml │ ├── condition.mli │ ├── event.ml │ ├── event.mli │ ├── libthreads.clib │ ├── mutex.ml │ ├── mutex.mli │ ├── st_posix.h │ ├── st_stubs.c │ ├── st_win32.h │ ├── thread.ml │ ├── thread.mli │ ├── threadUnix.ml │ ├── threadUnix.mli │ ├── threads.h │ └── threads.mllib ├── threads │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── condition.ml │ ├── condition.mli │ ├── event.ml │ ├── event.mli │ ├── libvmthreads.clib │ ├── marshal.ml │ ├── mutex.ml │ ├── mutex.mli │ ├── pervasives.ml │ ├── scheduler.c │ ├── thread.ml │ ├── thread.mli │ ├── threadUnix.ml │ ├── threadUnix.mli │ ├── threads.mllib │ ├── unix.ml │ └── unix.mllib ├── unix │ ├── .cvsignore │ ├── .depend │ ├── Makefile │ ├── accept.c │ ├── access.c │ ├── addrofstr.c │ ├── alarm.c │ ├── bind.c │ ├── chdir.c │ ├── chmod.c │ ├── chown.c │ ├── chroot.c │ ├── close.c │ ├── closedir.c │ ├── connect.c │ ├── cst2constr.c │ ├── cst2constr.h │ ├── cstringv.c │ ├── dup.c │ ├── dup2.c │ ├── envir.c │ ├── errmsg.c │ ├── execv.c │ ├── execve.c │ ├── execvp.c │ ├── exit.c │ ├── fchmod.c │ ├── fchown.c │ ├── fcntl.c │ ├── fork.c │ ├── ftruncate.c │ ├── getaddrinfo.c │ ├── getcwd.c │ ├── getegid.c │ ├── geteuid.c │ ├── getgid.c │ ├── getgr.c │ ├── getgroups.c │ ├── gethost.c │ ├── gethostname.c │ ├── getlogin.c │ ├── getnameinfo.c │ ├── getpeername.c │ ├── getpid.c │ ├── getppid.c │ ├── getproto.c │ ├── getpw.c │ ├── getserv.c │ ├── getsockname.c │ ├── gettimeofday.c │ ├── getuid.c │ ├── gmtime.c │ ├── initgroups.c │ ├── isatty.c │ ├── itimer.c │ ├── kill.c │ ├── libunix.clib │ ├── link.c │ ├── listen.c │ ├── lockf.c │ ├── lseek.c │ ├── mkdir.c │ ├── mkfifo.c │ ├── nice.c │ ├── open.c │ ├── opendir.c │ ├── pipe.c │ ├── putenv.c │ ├── read.c │ ├── readdir.c │ ├── readlink.c │ ├── rename.c │ ├── rewinddir.c │ ├── rmdir.c │ ├── select.c │ ├── sendrecv.c │ ├── setgid.c │ ├── setgroups.c │ ├── setsid.c │ ├── setuid.c │ ├── shutdown.c │ ├── signals.c │ ├── sleep.c │ ├── socket.c │ ├── socketaddr.c │ ├── socketaddr.h │ ├── socketpair.c │ ├── sockopt.c │ ├── stat.c │ ├── strofaddr.c │ ├── symlink.c │ ├── termios.c │ ├── time.c │ ├── times.c │ ├── truncate.c │ ├── umask.c │ ├── unix.ml │ ├── unix.mli │ ├── unix.mllib │ ├── unixLabels.ml │ ├── unixLabels.mli │ ├── unixsupport.c │ ├── unixsupport.h │ ├── unlink.c │ ├── utimes.c │ ├── wait.c │ └── write.c ├── win32graph │ ├── .cvsignore │ ├── Makefile.nt │ ├── dib.c │ ├── draw.c │ ├── events.c │ ├── libgraph.h │ ├── libgraphics.clib │ └── open.c └── win32unix │ ├── .cvsignore │ ├── .depend │ ├── Makefile.nt │ ├── accept.c │ ├── bind.c │ ├── channels.c │ ├── close.c │ ├── close_on.c │ ├── connect.c │ ├── createprocess.c │ ├── dup.c │ ├── dup2.c │ ├── errmsg.c │ ├── getpeername.c │ ├── getpid.c │ ├── getsockname.c │ ├── gettimeofday.c │ ├── libunix.clib │ ├── link.c │ ├── listen.c │ ├── lockf.c │ ├── lseek.c │ ├── mkdir.c │ ├── nonblock.c │ ├── open.c │ ├── pipe.c │ ├── read.c │ ├── rename.c │ ├── select.c │ ├── sendrecv.c │ ├── shutdown.c │ ├── sleep.c │ ├── socket.c │ ├── socketaddr.h │ ├── sockopt.c │ ├── startup.c │ ├── stat.c │ ├── system.c │ ├── unix.ml │ ├── unixsupport.c │ ├── unixsupport.h │ ├── windbug.c │ ├── windbug.h │ ├── windir.c │ ├── winlist.c │ ├── winlist.h │ ├── winwait.c │ ├── winworker.c │ ├── winworker.h │ └── write.c ├── parsing ├── .cvsignore ├── asttypes.mli ├── lexer.mli ├── lexer.mll ├── linenum.mli ├── linenum.mll ├── location.ml ├── location.mli ├── longident.ml ├── longident.mli ├── parse.ml ├── parse.mli ├── parser.mly ├── parsetree.mli ├── printast.ml ├── printast.mli ├── syntaxerr.ml └── syntaxerr.mli ├── stdlib ├── .cvsignore ├── .depend ├── Compflags ├── Makefile ├── Makefile.nt ├── Makefile.shared ├── StdlibModules ├── arg.ml ├── arg.mli ├── array.ml ├── array.mli ├── arrayLabels.ml ├── arrayLabels.mli ├── buffer.ml ├── buffer.mli ├── callback.ml ├── callback.mli ├── camlinternalLazy.ml ├── camlinternalLazy.mli ├── camlinternalMod.ml ├── camlinternalMod.mli ├── camlinternalOO.ml ├── camlinternalOO.mli ├── char.ml ├── char.mli ├── complex.ml ├── complex.mli ├── digest.ml ├── digest.mli ├── filename.ml ├── filename.mli ├── format.ml ├── format.mli ├── gc.ml ├── gc.mli ├── genlex.ml ├── genlex.mli ├── hashtbl.ml ├── hashtbl.mli ├── header.c ├── headernt.c ├── int32.ml ├── int32.mli ├── int64.ml ├── int64.mli ├── lazy.ml ├── lazy.mli ├── lexing.ml ├── lexing.mli ├── list.ml ├── list.mli ├── listLabels.ml ├── listLabels.mli ├── map.ml ├── map.mli ├── marshal.ml ├── marshal.mli ├── moreLabels.ml ├── moreLabels.mli ├── nativeint.ml ├── nativeint.mli ├── obj.ml ├── obj.mli ├── oo.ml ├── oo.mli ├── parsing.ml ├── parsing.mli ├── pervasives.ml ├── pervasives.mli ├── printexc.ml ├── printexc.mli ├── printf.ml ├── printf.mli ├── queue.ml ├── queue.mli ├── random.ml ├── random.mli ├── scanf.ml ├── scanf.mli ├── set.ml ├── set.mli ├── sharpbang ├── sort.ml ├── sort.mli ├── stack.ml ├── stack.mli ├── stdLabels.ml ├── stdLabels.mli ├── std_exit.ml ├── stdlib.mllib ├── stream.ml ├── stream.mli ├── string.ml ├── string.mli ├── stringLabels.ml ├── stringLabels.mli ├── sys.mli ├── sys.mlp ├── weak.ml └── weak.mli ├── testlabl ├── .cvsignore ├── coerce.diffs ├── dirs_multimatch ├── dirs_poly ├── els.ml ├── fixedtypes.ml ├── marshal_objects.diffs ├── multimatch.diffs ├── multimatch.ml ├── newlabels.ps ├── objvariant.diffs ├── objvariant.ml ├── printers.ml ├── sigsubst.ml ├── tests.ml ├── valvirt.diffs └── varunion.ml ├── testsuite ├── .svnignore ├── Makefile ├── interactive │ ├── lib-gc │ │ ├── Makefile │ │ ├── alloc.ml │ │ └── alloc.result │ ├── lib-graph-2 │ │ ├── Makefile │ │ ├── graph_test.ml │ │ └── graph_test.reference │ ├── lib-graph-3 │ │ ├── Makefile │ │ ├── sorts.ml │ │ └── sorts.reference │ ├── lib-graph │ │ ├── Makefile │ │ ├── graph_example.ml │ │ └── graph_example.reference │ └── lib-signals │ │ ├── Makefile │ │ └── signals.ml ├── lib │ ├── Makefile │ ├── testing.ml │ └── testing.mli ├── makefiles │ ├── Makefile.common │ ├── Makefile.okbad │ ├── Makefile.one │ ├── Makefile.several │ └── Makefile.toplevel └── tests │ ├── asmcomp │ ├── .svnignore │ ├── Makefile │ ├── alpha.S │ ├── amd64.S │ ├── arith.cmm │ ├── arm.S │ ├── checkbound.cmm │ ├── fib.cmm │ ├── hppa.S │ ├── i386.S │ ├── i386nt.asm │ ├── ia64.S │ ├── integr.cmm │ ├── lexcmm.mli │ ├── lexcmm.mll │ ├── m68k.S │ ├── main.c │ ├── main.ml │ ├── mainarith.c │ ├── mips.s │ ├── parsecmm.mly │ ├── parsecmmaux.ml │ ├── parsecmmaux.mli │ ├── power-aix.S │ ├── power-elf.S │ ├── power-rhapsody.S │ ├── quicksort.cmm │ ├── quicksort2.cmm │ ├── soli.cmm │ ├── sparc.S │ ├── tagged-fib.cmm │ ├── tagged-integr.cmm │ ├── tagged-quicksort.cmm │ ├── tagged-tak.cmm │ └── tak.cmm │ ├── backtrace │ ├── Makefile │ ├── backtrace..reference │ ├── backtrace.a.reference │ ├── backtrace.b.reference │ ├── backtrace.c.reference │ ├── backtrace.d.reference │ ├── backtrace.ml │ ├── backtrace2..reference │ ├── backtrace2.a.reference │ ├── backtrace2.b.reference │ ├── backtrace2.c.reference │ ├── backtrace2.d.reference │ └── backtrace2.ml │ ├── basic-float │ ├── Makefile │ ├── float_record.ml │ ├── float_record.mli │ ├── tfloat_record.ml │ └── tfloat_record.reference │ ├── basic-io-2 │ ├── Makefile │ ├── io.ml │ └── io.reference │ ├── basic-io │ ├── Makefile │ ├── wc.ml │ └── wc.reference │ ├── basic-manyargs │ ├── Makefile │ ├── manyargs.ml │ ├── manyargs.reference │ └── manyargsprim.c │ ├── basic-more │ ├── Makefile │ ├── bounds.ml │ ├── bounds.reference │ ├── morematch.ml │ ├── morematch.reference │ ├── tbuffer.ml │ ├── tbuffer.reference │ ├── testrandom.ml │ ├── testrandom.reference │ ├── tformat.ml │ ├── tformat.reference │ ├── tprintf.ml │ └── tprintf.reference │ ├── basic-multdef │ ├── Makefile │ ├── multdef.ml │ ├── multdef.mli │ ├── usemultdef.ml │ └── usemultdef.reference │ ├── basic-private │ ├── Makefile │ ├── length.ml │ ├── length.mli │ ├── tlength.ml │ └── tlength.reference │ ├── basic │ ├── Makefile │ ├── arrays.ml │ ├── arrays.reference │ ├── bigints.ml │ ├── bigints.reference │ ├── boxedints.ml │ ├── boxedints.reference │ ├── equality.ml │ ├── equality.reference │ ├── float.ml │ ├── float.reference │ ├── includestruct.ml │ ├── includestruct.reference │ ├── maps.ml │ ├── maps.reference │ ├── patmatch.ml │ ├── patmatch.reference │ ├── recvalues.ml │ ├── recvalues.reference │ ├── sets.ml │ ├── sets.reference │ ├── tailcalls.ml │ └── tailcalls.reference │ ├── callback │ ├── Makefile │ ├── callbackprim.c │ ├── reference │ └── tcallback.ml │ ├── embedded │ ├── .svnignore │ ├── Makefile │ ├── cmcaml.ml │ ├── cmmain.c │ ├── cmstub.c │ └── program.reference │ ├── gc-roots │ ├── .svnignore │ ├── Makefile │ ├── globroots.ml │ ├── globroots.reference │ └── globrootsprim.c │ ├── lib-bigarray-2 │ ├── Makefile │ ├── bigarrf.f │ ├── bigarrfml.ml │ ├── bigarrfml.reference │ └── bigarrfstub.c │ ├── lib-bigarray │ ├── Makefile │ ├── bigarrays.ml │ ├── bigarrays.reference │ ├── fftba.ml │ ├── fftba.reference │ ├── pr5115.ml │ └── pr5115.reference │ ├── lib-digest │ ├── .svnignore │ ├── Makefile │ ├── md5.ml │ └── md5.reference │ ├── lib-dynlink-bytecode │ ├── .svnignore │ ├── Makefile │ ├── custom.reference │ ├── main.ml │ ├── main.reference │ ├── plug1.ml │ ├── plug2.ml │ ├── static.reference │ ├── stub1.c │ └── stub2.c │ ├── lib-dynlink-csharp │ ├── Makefile │ ├── bytecode.reference │ ├── entry.c │ ├── main.cs │ ├── main.ml │ ├── native.reference │ └── plugin.ml │ ├── lib-dynlink-native │ ├── .svnignore │ ├── Makefile │ ├── a.ml │ ├── api.ml │ ├── b.ml │ ├── bug.ml │ ├── c.ml │ ├── factorial.c │ ├── main.ml │ ├── pack_client.ml │ ├── packed1.ml │ ├── packed1_client.ml │ ├── plugin.ml │ ├── plugin.mli │ ├── plugin2.ml │ ├── plugin4.ml │ ├── plugin_ext.ml │ ├── plugin_high_arity.ml │ ├── plugin_ref.ml │ ├── plugin_simple.ml │ ├── plugin_thread.ml │ ├── reference │ └── sub │ │ ├── api.ml │ │ ├── api.mli │ │ ├── plugin.ml │ │ └── plugin3.ml │ ├── lib-marshal │ ├── Makefile │ ├── intext.ml │ ├── intext.reference │ └── intextaux.c │ ├── lib-num-2 │ ├── Makefile │ ├── pi_big_int.ml │ ├── pi_big_int.reference │ ├── pi_num.ml │ └── pi_num.reference │ ├── lib-num │ ├── Makefile │ ├── end_test.ml │ ├── end_test.reference │ ├── test.ml │ ├── test_big_ints.ml │ ├── test_io.ml │ ├── test_nats.ml │ ├── test_nums.ml │ └── test_ratios.ml │ ├── lib-scanf-2 │ ├── Makefile │ ├── reference │ ├── tscanf2_io.ml │ ├── tscanf2_master.ml │ └── tscanf2_slave.ml │ ├── lib-scanf │ ├── Makefile │ ├── tscanf.ml │ ├── tscanf.reference │ └── tscanf_data │ ├── lib-str │ ├── Makefile │ ├── t01.ml │ └── t01.reference │ ├── lib-systhreads │ ├── Makefile │ ├── testfork.ml │ └── testfork.reference │ ├── lib-threads │ ├── .cvsignore │ ├── Makefile │ ├── close.ml │ ├── close.reference │ ├── sieve.ml │ ├── sieve.reference │ ├── test1.checker │ ├── test1.ml │ ├── test1.reference │ ├── test2.checker │ ├── test2.ml │ ├── test3.checker │ ├── test3.ml │ ├── test3.runner │ ├── test4.checker │ ├── test4.data │ ├── test4.ml │ ├── test4.reference │ ├── test4.runner │ ├── test5.checker │ ├── test5.ml │ ├── test5.reference │ ├── test5.runner │ ├── test6.checker │ ├── test6.ml │ ├── test6.reference │ ├── test6.runner │ ├── test7.checker │ ├── test7.ml │ ├── test7.runner │ ├── test8.ml │ ├── test8.reference │ ├── test9.ml │ ├── test9.reference │ ├── testA.checker │ ├── testA.ml │ ├── testA.reference │ ├── testexit.checker │ ├── testexit.ml │ ├── testexit.reference │ ├── testio.ml │ ├── testio.reference │ ├── testsieve.ml │ ├── testsieve.reference │ ├── testsignal.checker │ ├── testsignal.ml │ ├── testsignal.runner │ ├── testsignal2.checker │ ├── testsignal2.ml │ ├── testsignal2.runner │ ├── testsocket.ml │ ├── testsocket.reference │ ├── token1.ml │ ├── token1.reference │ ├── token2.ml │ ├── token2.reference │ ├── torture.data │ ├── torture.ml │ ├── torture.reference │ └── torture.runner │ ├── misc-kb │ ├── Makefile │ ├── equations.ml │ ├── equations.mli │ ├── kb.ml │ ├── kb.mli │ ├── kbmain.ml │ ├── kbmain.reference │ ├── orderings.ml │ ├── orderings.mli │ ├── terms.ml │ └── terms.mli │ ├── misc-unsafe │ ├── Makefile │ ├── almabench.ml │ ├── almabench.reference │ ├── fft.ml │ ├── fft.reference │ ├── quicksort.ml │ ├── quicksort.reference │ ├── soli.ml │ └── soli.reference │ ├── misc │ ├── Makefile │ ├── bdd.ml │ ├── bdd.reference │ ├── boyer.ml │ ├── boyer.reference │ ├── fib.ml │ ├── fib.reference │ ├── hamming.ml │ ├── hamming.reference │ ├── nucleic.ml │ ├── nucleic.reference │ ├── sieve.ml │ ├── sieve.reference │ ├── sorts.ml │ ├── sorts.reference │ ├── takc.ml │ ├── takc.reference │ ├── taku.ml │ ├── taku.reference │ ├── weaktest.ml │ └── weaktest.reference │ ├── regression-camlp4-class-type-plus │ ├── Makefile │ └── camlp4_class_type_plus_ok.ml │ ├── regression-pr5080-notes │ ├── Makefile │ └── pr5080_notes_ok.ml │ ├── runtime-errors │ ├── .svnignore │ ├── Makefile │ ├── stackoverflow.bytecode.reference │ ├── stackoverflow.ml │ ├── stackoverflow.native.reference │ ├── syserror.bytecode.reference │ ├── syserror.ml │ └── syserror.native.reference │ ├── tool-lexyacc │ ├── .svnignore │ ├── Makefile │ ├── gram_aux.ml │ ├── grammar.mly │ ├── input │ ├── input.ml │ ├── lexgen.ml │ ├── main.ml │ ├── main.reference │ ├── output.ml │ ├── scan_aux.ml │ ├── scanner.mll │ └── syntax.ml │ ├── tool-ocaml │ ├── Makefile │ ├── lib.ml │ ├── t000.ml │ ├── t010-const0.ml │ ├── t010-const1.ml │ ├── t010-const2.ml │ ├── t010-const3.ml │ ├── t011-constint.ml │ ├── t020.ml │ ├── t021-pushconst1.ml │ ├── t021-pushconst2.ml │ ├── t021-pushconst3.ml │ ├── t022-pushconstint.ml │ ├── t040-makeblock1.ml │ ├── t040-makeblock2.ml │ ├── t040-makeblock3.ml │ ├── t041-makeblock.ml │ ├── t050-getglobal.ml │ ├── t050-pushgetglobal.ml │ ├── t051-getglobalfield.ml │ ├── t051-pushgetglobalfield.ml │ ├── t060-raise.ml │ ├── t070-branch.ml │ ├── t070-branchif.ml │ ├── t070-branchifnot.ml │ ├── t071-boolnot.ml │ ├── t080-eq.ml │ ├── t080-geint.ml │ ├── t080-gtint.ml │ ├── t080-leint.ml │ ├── t080-ltint.ml │ ├── t080-neq.ml │ ├── t090-acc0.ml │ ├── t090-acc1.ml │ ├── t090-acc2.ml │ ├── t090-acc3.ml │ ├── t090-acc4.ml │ ├── t090-acc5.ml │ ├── t090-acc6.ml │ ├── t090-acc7.ml │ ├── t091-acc.ml │ ├── t092-pushacc.ml │ ├── t092-pushacc0.ml │ ├── t092-pushacc1.ml │ ├── t092-pushacc2.ml │ ├── t092-pushacc3.ml │ ├── t092-pushacc4.ml │ ├── t092-pushacc5.ml │ ├── t092-pushacc6.ml │ ├── t092-pushacc7.ml │ ├── t093-pushacc.ml │ ├── t100-pushtrap.ml │ ├── t101-poptrap.ml │ ├── t110-addint.ml │ ├── t110-andint.ml │ ├── t110-asrint-1.ml │ ├── t110-asrint-2.ml │ ├── t110-divint-1.ml │ ├── t110-divint-2.ml │ ├── t110-divint-3.ml │ ├── t110-lslint.ml │ ├── t110-lsrint.ml │ ├── t110-modint-1.ml │ ├── t110-modint-2.ml │ ├── t110-mulint.ml │ ├── t110-negint.ml │ ├── t110-offsetint.ml │ ├── t110-orint.ml │ ├── t110-subint.ml │ ├── t110-xorint.ml │ ├── t120-getstringchar.ml │ ├── t121-setstringchar.ml │ ├── t130-getvectitem.ml │ ├── t130-vectlength.ml │ ├── t131-setvectitem.ml │ ├── t140-switch-1.ml │ ├── t140-switch-2.ml │ ├── t140-switch-3.ml │ ├── t140-switch-4.ml │ ├── t141-switch-5.ml │ ├── t141-switch-6.ml │ ├── t141-switch-7.ml │ ├── t142-switch-8.ml │ ├── t142-switch-9.ml │ ├── t142-switch-A.ml │ ├── t150-push-1.ml │ ├── t150-push-2.ml │ ├── t160-closure.ml │ ├── t161-apply1.ml │ ├── t162-return.ml │ ├── t163.ml │ ├── t164-apply2.ml │ ├── t164-apply3.ml │ ├── t165-apply.ml │ ├── t170-envacc2.ml │ ├── t170-envacc3.ml │ ├── t170-envacc4.ml │ ├── t171-envacc.ml │ ├── t172-pushenvacc1.ml │ ├── t172-pushenvacc2.ml │ ├── t172-pushenvacc3.ml │ ├── t172-pushenvacc4.ml │ ├── t173-pushenvacc.ml │ ├── t180-appterm1.ml │ ├── t180-appterm2.ml │ ├── t180-appterm3.ml │ ├── t181-appterm.ml │ ├── t190-makefloatblock-1.ml │ ├── t190-makefloatblock-2.ml │ ├── t190-makefloatblock-3.ml │ ├── t191-vectlength.ml │ ├── t192-getfloatfield-1.ml │ ├── t192-getfloatfield-2.ml │ ├── t193-setfloatfield-1.ml │ ├── t193-setfloatfield-2.ml │ ├── t200-getfield0.ml │ ├── t200-getfield1.ml │ ├── t200-getfield2.ml │ ├── t200-getfield3.ml │ ├── t201-getfield.ml │ ├── t210-setfield0.ml │ ├── t210-setfield1.ml │ ├── t210-setfield2.ml │ ├── t210-setfield3.ml │ ├── t211-setfield.ml │ ├── t220-assign.ml │ ├── t230-check_signals.ml │ ├── t240-c_call1.ml │ ├── t240-c_call2.ml │ ├── t240-c_call3.ml │ ├── t240-c_call4.ml │ ├── t240-c_call5.ml │ ├── t250-closurerec-1.ml │ ├── t250-closurerec-2.ml │ ├── t251-pushoffsetclosure0.ml │ ├── t251-pushoffsetclosure2.ml │ ├── t251-pushoffsetclosurem2.ml │ ├── t252-pushoffsetclosure.ml │ ├── t253-offsetclosure0.ml │ ├── t253-offsetclosure2.ml │ ├── t253-offsetclosurem2.ml │ ├── t254-offsetclosure.ml │ ├── t260-offsetref.ml │ ├── t270-push_retaddr.ml │ ├── t300-getmethod.ml │ ├── t301-object.ml │ ├── t310-alloc-1.ml │ ├── t310-alloc-2.ml │ ├── t320-gc-1.ml │ ├── t320-gc-2.ml │ ├── t320-gc-3.ml │ ├── t330-compact-1.ml │ ├── t330-compact-2.ml │ ├── t330-compact-3.ml │ ├── t330-compact-4.ml │ ├── t340-weak.ml │ ├── t350-heapcheck.ml │ ├── t360-stacks-1.ml │ └── t360-stacks-2.ml │ ├── tool-ocamldoc │ ├── .svnignore │ ├── Makefile │ ├── odoc_test.ml │ ├── t01.ml │ ├── t01.reference │ ├── t02.ml │ ├── t02.reference │ ├── t03.ml │ └── t03.reference │ ├── typing-fstclassmod │ ├── .svnignore │ ├── Makefile │ ├── fstclassmod.ml │ └── fstclassmod.reference │ ├── typing-labels │ ├── .svnignore │ ├── Makefile │ ├── mixin.ml │ ├── mixin.reference │ ├── mixin2.ml │ ├── mixin2.reference │ ├── mixin3.ml │ └── mixin3.reference │ ├── typing-modules-bugs │ ├── Makefile │ └── pr5164_ok.ml │ ├── typing-modules │ ├── Makefile │ ├── Test.ml │ └── Test.ml.reference │ ├── typing-objects-bugs │ ├── Makefile │ ├── pr3968_bad.ml │ ├── pr4018_bad.ml │ ├── pr4435_bad.ml │ ├── pr4766_ok.ml │ ├── pr4824_ok.ml │ ├── pr4824a_bad.ml │ ├── pr5156_ok.ml │ ├── woodyatt_ok.ml │ └── yamagata021012_ok.ml │ ├── typing-objects │ ├── .svnignore │ ├── Exemples.ml │ ├── Exemples.ml.reference │ ├── Makefile │ ├── Tests.ml │ └── Tests.ml.reference │ ├── typing-poly │ ├── .svnignore │ ├── Makefile │ ├── poly.ml │ ├── poly.ml.principal.reference │ └── poly.ml.reference │ ├── typing-polyvariants-bugs-2 │ ├── Makefile │ ├── pr3918a.mli │ ├── pr3918b.mli │ └── pr3918c.ml │ ├── typing-polyvariants-bugs │ ├── Makefile │ ├── pr4775_ok.ml │ ├── pr4933_ok.ml │ ├── pr5057_ok.ml │ ├── pr5057a_bad.ml │ └── privrowsabate_ok.ml │ ├── typing-private-bugs │ ├── Makefile │ └── pr5026_bad.ml │ ├── typing-private │ ├── .svnignore │ ├── Makefile │ ├── private.ml │ └── private.ml.reference │ ├── typing-recmod │ ├── Makefile │ ├── t01bad.ml │ ├── t02bad.ml │ ├── t03ok.ml │ ├── t04bad.ml │ ├── t05bad.ml │ ├── t06ok.ml │ ├── t07bad.ml │ ├── t08bad.ml │ ├── t09bad.ml │ ├── t10ok.ml │ ├── t11bad.ml │ ├── t12bad.ml │ ├── t13ok.ml │ ├── t14bad.ml │ ├── t15bad.ml │ ├── t16ok.ml │ ├── t17ok.ml │ ├── t18ok.ml │ ├── t19ok.ml │ ├── t20ok.ml │ ├── t21ok.ml │ ├── t22ok.ml │ └── t22ok.mli │ ├── typing-typeparam │ ├── .svnignore │ ├── Makefile │ ├── newtype.ml │ └── newtype.reference │ └── warnings │ ├── Makefile │ ├── w01.ml │ └── w01.reference ├── tools ├── .cvsignore ├── .depend ├── Characters ├── DoMake ├── MakeDepend ├── Makefile ├── Makefile.nt ├── Makefile.shared ├── OCamlc-custom ├── Time ├── addlabels.ml ├── checkstack.c ├── cleanup-header ├── cvt_emit.mll ├── depend.ml ├── depend.mli ├── dumpobj.ml ├── lexer299.mll ├── lexer301.mll ├── magic ├── make-opcodes ├── make-package-macosx ├── objinfo.ml ├── objinfo_helper.c ├── ocaml-objcopy-macosx ├── ocaml299to3.ml ├── ocamlcp.ml ├── ocamldep.ml ├── ocamlmklib.mlp ├── ocamlmktop.ml ├── ocamlmktop.tpl ├── ocamlprof.ml ├── ocamlsize ├── primreq.ml ├── profiling.ml ├── profiling.mli └── scrapelabels.ml ├── toplevel ├── expunge.ml ├── genprintval.ml ├── genprintval.mli ├── opttopdirs.ml ├── opttopdirs.mli ├── opttoploop.ml ├── opttoploop.mli ├── opttopmain.ml ├── opttopmain.mli ├── opttopstart.ml ├── topdirs.ml ├── topdirs.mli ├── toplevellib.mllib ├── toploop.ml ├── toploop.mli ├── topmain.ml ├── topmain.mli ├── topstart.ml ├── trace.ml └── trace.mli ├── typing ├── annot.mli ├── btype.ml ├── btype.mli ├── ctype.ml ├── ctype.mli ├── datarepr.ml ├── datarepr.mli ├── env.ml ├── env.mli ├── ident.ml ├── ident.mli ├── includeclass.ml ├── includeclass.mli ├── includecore.ml ├── includecore.mli ├── includemod.ml ├── includemod.mli ├── mtype.ml ├── mtype.mli ├── oprint.ml ├── oprint.mli ├── outcometree.mli ├── parmatch.ml ├── parmatch.mli ├── path.ml ├── path.mli ├── predef.ml ├── predef.mli ├── primitive.ml ├── primitive.mli ├── printtyp.ml ├── printtyp.mli ├── stypes.ml ├── stypes.mli ├── subst.ml ├── subst.mli ├── typeclass.ml ├── typeclass.mli ├── typecore.ml ├── typecore.mli ├── typedecl.ml ├── typedecl.mli ├── typedtree.ml ├── typedtree.mli ├── typemod.ml ├── typemod.mli ├── types.ml ├── types.mli ├── typetexp.ml ├── typetexp.mli ├── unused_var.ml └── unused_var.mli ├── utils ├── .cvsignore ├── ccomp.ml ├── ccomp.mli ├── clflags.ml ├── clflags.mli ├── config.mlbuild ├── config.mli ├── config.mlp ├── consistbl.ml ├── consistbl.mli ├── misc.ml ├── misc.mli ├── tbl.ml ├── tbl.mli ├── terminfo.ml ├── terminfo.mli ├── warnings.ml └── warnings.mli ├── win32caml ├── Makefile ├── editbuffer.c ├── editbuffer.h ├── history.c ├── history.h ├── inria.h ├── inriares.h ├── libgraph.h ├── menu.c ├── ocaml.c ├── ocaml.ico ├── ocaml.rc ├── resource.h └── startocaml.c └── yacc ├── .cvsignore ├── Makefile ├── Makefile.nt ├── closure.c ├── defs.h ├── error.c ├── lalr.c ├── lr0.c ├── main.c ├── mkpar.c ├── output.c ├── reader.c ├── skeleton.c ├── symtab.c ├── verbose.c └── warshall.c /.cvsignore: -------------------------------------------------------------------------------- 1 | .depend 2 | configure 3 | ocamlc 4 | ocamlc.opt 5 | expunge 6 | ocaml 7 | ocamlopt 8 | ocamlopt.opt 9 | ocamlcomp.sh 10 | ocamlcompopt.sh 11 | package-macosx 12 | .DS_Store 13 | *.annot 14 | _boot_log1 15 | _boot_log2 16 | _build 17 | _log 18 | myocamlbuild_config.ml 19 | ocamlnat 20 | -------------------------------------------------------------------------------- /Changes: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/Changes -------------------------------------------------------------------------------- /VERSION: -------------------------------------------------------------------------------- 1 | 3.12.1 2 | 3 | # The version string is the first line of this file. 4 | # It must be in the format described in stdlib/sys.mli 5 | 6 | # $Id$ 7 | -------------------------------------------------------------------------------- /asmcomp/.cvsignore: -------------------------------------------------------------------------------- 1 | emit.ml 2 | arch.ml 3 | proc.ml 4 | selection.ml 5 | reload.ml 6 | scheduling.ml 7 | -------------------------------------------------------------------------------- /asmcomp/llvmcompile.mli: -------------------------------------------------------------------------------- 1 | open Cmm 2 | 3 | val compile_fundecl : fundecl -> unit 4 | 5 | val data : data_item list -> unit 6 | -------------------------------------------------------------------------------- /asmcomp/m68k/README: -------------------------------------------------------------------------------- 1 | As of Feb 4th 2000, the native-code compiler for the Motorola 680x0 is 2 | no longer maintained and thus deprecated. 3 | 4 | The only machines on which we could test this port (Sun 3, SunOS 4) 5 | here at INRIA are being retired, and were so slow that the port wasn't 6 | kept up-to-date with the remainder of the system. 7 | 8 | - Xavier Leroy, for the Objective Caml development team. 9 | -------------------------------------------------------------------------------- /asmrun/.cvsignore: -------------------------------------------------------------------------------- 1 | libasmrun.a 2 | libasmrunp.a 3 | main.c 4 | misc.c 5 | freelist.c 6 | major_gc.c 7 | minor_gc.c 8 | memory.c 9 | alloc.c 10 | array.c 11 | compare.c 12 | ints.c 13 | floats.c 14 | str.c 15 | io.c 16 | extern.c 17 | intern.c 18 | hash.c 19 | sys.c 20 | parsing.c 21 | gc_ctrl.c 22 | terminfo.c 23 | md5.c 24 | obj.c 25 | lexing.c 26 | printexc.c 27 | callback.c 28 | weak.c 29 | compact.c 30 | finalise.c 31 | custom.c 32 | meta.c 33 | globroots.c 34 | unix.c 35 | dynlink.c 36 | signals.c 37 | debugger.c 38 | .depend.nt 39 | -------------------------------------------------------------------------------- /asmrun/natdynlink.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/asmrun/natdynlink.h -------------------------------------------------------------------------------- /boot/.cvsignore: -------------------------------------------------------------------------------- 1 | Saved 2 | ocamlrun 3 | ocamlyacc 4 | camlheader 5 | myocamlbuild 6 | myocamlbuild.native 7 | libcamlrun.a 8 | -------------------------------------------------------------------------------- /boot/myocamlbuild.boot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/boot/myocamlbuild.boot -------------------------------------------------------------------------------- /boot/ocamlc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/boot/ocamlc -------------------------------------------------------------------------------- /boot/ocamldep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/boot/ocamldep -------------------------------------------------------------------------------- /boot/ocamllex: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/boot/ocamllex -------------------------------------------------------------------------------- /build/.cvsignore: -------------------------------------------------------------------------------- 1 | ocamlbuild_mixed_mode 2 | -------------------------------------------------------------------------------- /build/mkconfig.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | cd `dirname $0`/.. 4 | 5 | sed -e 's/^\(.*\$([0-9]).*\)$/# \1/' \ 6 | -e 's/\$(\([^)]*\))/${\1}/g' \ 7 | -e 's/^FLEX.*$//g' \ 8 | -e 's/^\([^#=]*\)=\([^"]*\)$/if [ "x$\1" = "x" ]; then \1="\2"; fi/' \ 9 | config/Makefile > config/config.sh 10 | 11 | if [ "x$EXE" = "x.exe" -a "x$SYSTEM" != "xcygwin" ]; then 12 | echo "WINDOWS=true" >> config/config.sh 13 | else 14 | echo "WINDOWS=false" >> config/config.sh 15 | fi 16 | -------------------------------------------------------------------------------- /build/mkruntimedef.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # $Id$ 3 | echo 'let builtin_exceptions = [|'; \ 4 | sed -n -e 's|.*/\* \("[A-Za-z_]*"\) \*/$| \1;|p' byterun/fail.h | \ 5 | sed -e '$s/;$//'; \ 6 | echo '|]'; \ 7 | echo 'let builtin_primitives = [|'; \ 8 | sed -e 's/.*/ "&";/' -e '$s/;$//' byterun/primitives; \ 9 | echo '|]' 10 | -------------------------------------------------------------------------------- /build/tolower.sed: -------------------------------------------------------------------------------- 1 | # tolower.sed expands one ...<:lower>... to ...foo... per line 2 | h 3 | s/.*<:lower<\(.*\)>>.*/\1/ 4 | t cont 5 | b end 6 | :cont 7 | y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ 8 | s/$/|/ 9 | G 10 | s/\(.*\)|\n\(.*\)<:lower<\(.*\)>>/\2\1/ 11 | :end 12 | -------------------------------------------------------------------------------- /build/world.all.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # $Id$ 3 | set -e 4 | cd `dirname $0`/.. 5 | . build/targets.sh 6 | set -x 7 | $OCAMLBUILD $@ \ 8 | $STDLIB_BYTE $OCAMLC_BYTE $OCAMLLEX_BYTE $OCAMLOPT_BYTE $TOPLEVEL \ 9 | $TOOLS_BYTE $OTHERLIBS_BYTE $OCAMLBUILD_BYTE $DEBUGGER $OCAMLDOC_BYTE \ 10 | $CAMLP4_BYTE $STDLIB_NATIVE $OCAMLC_NATIVE $OCAMLOPT_NATIVE \ 11 | $OCAMLLEX_NATIVE $TOOLS_NATIVE $OTHERLIBS_NATIVE \ 12 | $OCAMLBUILD_NATIVE $OCAMLDOC_NATIVE $CAMLP4_NATIVE 13 | -------------------------------------------------------------------------------- /build/world.byte.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # $Id$ 3 | set -e 4 | cd `dirname $0`/.. 5 | . build/targets.sh 6 | set -x 7 | $OCAMLBUILD $@ \ 8 | $STDLIB_BYTE $OCAMLC_BYTE $OCAMLLEX_BYTE $OCAMLOPT_BYTE $TOPLEVEL $TOOLS_BYTE \ 9 | $OTHERLIBS_BYTE $OCAMLBUILD_BYTE $DEBUGGER $OCAMLDOC_BYTE $CAMLP4_BYTE 10 | -------------------------------------------------------------------------------- /build/world.native.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # $Id$ 3 | set -e 4 | cd `dirname $0`/.. 5 | . build/targets.sh 6 | set -x 7 | $OCAMLBUILD $@ \ 8 | $STDLIB_NATIVE $OCAMLC_NATIVE $OCAMLOPT_NATIVE \ 9 | $OCAMLLEX_NATIVE $TOOLS_NATIVE $OTHERLIBS_NATIVE \ 10 | $OCAMLBUILD_NATIVE $OCAMLDOC_NATIVE $CAMLP4_NATIVE 11 | -------------------------------------------------------------------------------- /bytecomp/.cvsignore: -------------------------------------------------------------------------------- 1 | runtimedef.ml 2 | opcodes.ml 3 | -------------------------------------------------------------------------------- /byterun/.cvsignore: -------------------------------------------------------------------------------- 1 | jumptbl.h 2 | primitives 3 | prims.c 4 | opnames.h 5 | version.h 6 | ocamlrun 7 | ocamlrund 8 | ld.conf 9 | libcamlrun.x 10 | libcamlrun-gui.x 11 | *.c.x 12 | ocamlrun.xcoff 13 | ocamlrun.dbg 14 | interp.a.lst 15 | *.[sd]obj 16 | *.lib 17 | .gdb_history 18 | *.so 19 | *.a 20 | .depend.nt 21 | -------------------------------------------------------------------------------- /camlp4/.cvsignore: -------------------------------------------------------------------------------- 1 | *.cm* 2 | .cache-status 3 | *.tmp.ml 4 | -------------------------------------------------------------------------------- /camlp4/Camlp4.mlpack: -------------------------------------------------------------------------------- 1 | Debug 2 | ErrorHandler 3 | OCamlInitSyntax 4 | Options 5 | PreCast 6 | Printers 7 | Register 8 | Sig 9 | Struct 10 | -------------------------------------------------------------------------------- /camlp4/Camlp4/.cvsignore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/camlp4/Camlp4/.cvsignore -------------------------------------------------------------------------------- /camlp4/Camlp4/Printers.mlpack: -------------------------------------------------------------------------------- 1 | DumpCamlp4Ast 2 | DumpOCamlAst 3 | Null 4 | OCaml 5 | OCamlr 6 | -------------------------------------------------------------------------------- /camlp4/Camlp4/Struct.mlpack: -------------------------------------------------------------------------------- 1 | AstFilters 2 | Camlp4Ast 3 | Camlp4Ast2OCamlAst 4 | CleanAst 5 | CommentFilter 6 | DynLoader 7 | EmptyError 8 | EmptyPrinter 9 | FreeVars 10 | Lexer 11 | Loc 12 | Quotation 13 | Token 14 | Grammar 15 | DynAst 16 | -------------------------------------------------------------------------------- /camlp4/Camlp4/Struct/.cvsignore: -------------------------------------------------------------------------------- 1 | Lexer.ml 2 | Camlp4Ast.tmp.ml 3 | -------------------------------------------------------------------------------- /camlp4/Camlp4/Struct/Grammar.mlpack: -------------------------------------------------------------------------------- 1 | Delete 2 | Dynamic 3 | Entry 4 | Failed 5 | Find 6 | Fold 7 | Insert 8 | Parser 9 | Print 10 | Search 11 | Static 12 | Structure 13 | Tools 14 | -------------------------------------------------------------------------------- /camlp4/Camlp4Filters/Camlp4MapGenerator.ml: -------------------------------------------------------------------------------- 1 | (* This module is useless now. Camlp4FoldGenerator handles map too. *) 2 | module Id = struct 3 | value name = "Camlp4MapGenerator"; 4 | value version = Sys.ocaml_version; 5 | end; 6 | -------------------------------------------------------------------------------- /camlp4/Camlp4Top.mlpack: -------------------------------------------------------------------------------- 1 | Top 2 | Rprint 3 | -------------------------------------------------------------------------------- /camlp4/boot/.cvsignore: -------------------------------------------------------------------------------- 1 | *.cm[oia] 2 | camlp4 3 | camlp4o 4 | camlp4r 5 | SAVED 6 | -------------------------------------------------------------------------------- /camlp4/build/.cvsignore: -------------------------------------------------------------------------------- 1 | camlp4_config.ml 2 | linenum.mli 3 | linenum.mll 4 | location.ml 5 | location.mli 6 | terminfo.ml 7 | terminfo.mli 8 | -------------------------------------------------------------------------------- /camlp4/camlp4.odocl: -------------------------------------------------------------------------------- 1 | Camlp4/Sig 2 | -------------------------------------------------------------------------------- /camlp4/camlp4lib.mllib: -------------------------------------------------------------------------------- 1 | Camlp4 2 | Camlp4_import 3 | Camlp4_config 4 | -------------------------------------------------------------------------------- /camlp4/camlp4prof.mli: -------------------------------------------------------------------------------- 1 | value count : string -> unit; 2 | 3 | value load : in_channel -> list (string * int); 4 | -------------------------------------------------------------------------------- /camlp4/examples/all.itarget: -------------------------------------------------------------------------------- 1 | apply_operator.cmo 2 | type_quotation.cmo 3 | lambda_quot.cmo 4 | lambda_quot_o.cmo 5 | macros.cmo 6 | parse_files.byte 7 | parse_files.native 8 | arith.cmo 9 | expression_closure.cmo 10 | expression_closure_filter.cmo 11 | global_handler.cmo 12 | -------------------------------------------------------------------------------- /camlp4/examples/apply_operator.ml: -------------------------------------------------------------------------------- 1 | open Camlp4.PreCast; 2 | AstFilters.register_str_item_filter 3 | (Ast.map_expr 4 | (fun 5 | [ <:expr@loc< $e1$ & $e2$ >> -> <:expr@loc< $e1$ $e2$ >> 6 | | e -> e ]))#str_item; 7 | -------------------------------------------------------------------------------- /camlp4/examples/apply_operator_test.ml: -------------------------------------------------------------------------------- 1 | let ( & ) = ();; (* To force it to be inlined. If not it's not well typed. *) 2 | 3 | fun f g h x -> f& g& h x 4 | -------------------------------------------------------------------------------- /camlp4/examples/ex_str_test.ml: -------------------------------------------------------------------------------- 1 | function <> -> <> 2 | -------------------------------------------------------------------------------- /camlp4/examples/expression_closure_test.ml: -------------------------------------------------------------------------------- 1 | (* x and y are free *) 2 | close_expr(x y);; 3 | 4 | (* bind x *) 5 | let x a = a + 42;; 6 | 7 | (* y is free *) 8 | close_expr(x y);; 9 | 10 | (* bind y locally so the expr is closed *) 11 | close_expr(let y = x 2 in x y);; 12 | 13 | (* bind y locally but outside, z is free *) 14 | let y = x 2 in close_expr(x (z y));; 15 | -------------------------------------------------------------------------------- /camlp4/examples/gen_match_case.ml: -------------------------------------------------------------------------------- 1 | open Camlp4.PreCast;; 2 | 3 | let gen patts exprs = 4 | let cases = 5 | List.fold_right2 begin fun patt expr acc -> 6 | let _loc = Loc.merge (Ast.loc_of_patt patt) (Ast.loc_of_expr expr) in 7 | <:match_case< $patt$ -> $expr$ | $acc$ >> 8 | end patts exprs <:match_case@here<>> 9 | in 10 | let _loc = Ast.loc_of_match_case cases in 11 | <:expr< function $cases$ >> 12 | ;; 13 | -------------------------------------------------------------------------------- /camlp4/examples/gettext_test.ml: -------------------------------------------------------------------------------- 1 | f "test", f "foo", "bar" 2 | -------------------------------------------------------------------------------- /camlp4/examples/global_handler_test.ml: -------------------------------------------------------------------------------- 1 | open Format;; 2 | let f1 x = printf "f1 %d@." x;; 3 | let f2 x = printf "f2 %f@." x;; 4 | let f3 x = printf "f3 %s@." x;; 5 | f1 1;; 6 | f2 1.1;; 7 | f3 "1.1.1";; 8 | raise (Failure "test");; 9 | let global_handler e = 10 | (* Note that I need to give the complete name for eprintf since 11 | Format is not opened in the new environment of global_handler. *) 12 | Format.eprintf "global_handler: %s@." (Printexc.to_string e) 13 | -------------------------------------------------------------------------------- /camlp4/examples/test.itarget: -------------------------------------------------------------------------------- 1 | test_macros.cmo 2 | lambda_test.cmo 3 | free_vars_test.byte 4 | free_vars_test.native 5 | global_handler_test.cmo 6 | apply_operator_test.cmo 7 | test_type_quotation.cmo 8 | expression_closure_test.cmo 9 | -------------------------------------------------------------------------------- /camlp4/examples/test_macros.ml: -------------------------------------------------------------------------------- 1 | (* DEFINE F(x, y, z) = x + y * z;; *) 2 | (* F(F(1, 2, 3), 4, 5);; *) 3 | 4 | (* !+ (1, 2, 3, 4);; *) 5 | 6 | (* foldl(( + ), 1, 2, 3, 4);; *) 7 | (* foldr(cons, 1, 2, 3, []);; *) 8 | 9 | let cons x xs = x :: xs;; 10 | 11 | def_foldl ( !+ ) ( + );; 12 | def_foldr ( !:: ) cons;; 13 | 14 | !+ (1, 2, 3, 4);; 15 | !:: (1, 2, 3, []);; 16 | -------------------------------------------------------------------------------- /camlp4/examples/test_type_quotation.ml: -------------------------------------------------------------------------------- 1 | type t1 = <:power< 6 | int >> 2 | type t2 = <:power< 3 | int -> int >> -> int 3 | type t3 = <:power< 3 | int -> <:power< 2 | int >> >> -> int 4 | -------------------------------------------------------------------------------- /camlp4/man/.cvsignore: -------------------------------------------------------------------------------- 1 | camlp4.1 2 | camlp4.help 3 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/assert.ml: -------------------------------------------------------------------------------- 1 | module MySet = Set.Make(String);; 2 | let set = MySet.empty;; 3 | assert (MySet.is_empty set);; 4 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/backquoted_irrefutable_tuple.ml: -------------------------------------------------------------------------------- 1 | EXTEND Gram 2 | abc: [ [ `(x,y) -> x + y ] ]; 3 | END; 4 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/backquoted_record.ml: -------------------------------------------------------------------------------- 1 | EXTEND Gram 2 | raw_string: 3 | [[ `QUOTATION { Sig.Quotation.q_contents = c; q_name = n } -> (c, n) ]]; 4 | END; 5 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/backquoted_tuple.ml: -------------------------------------------------------------------------------- 1 | EXTEND Gram 2 | abc: [ [ `(A,y) -> y ] ]; 3 | END; 4 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/bug-4058.ml: -------------------------------------------------------------------------------- 1 | let _ = (fun x -> x), 1 2 | let _ = (x := 1), 2 3 | let _ = (x <- 1), 2 4 | let _ = (if true then 1 else 2), 1 5 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/bug-4337.ml: -------------------------------------------------------------------------------- 1 | match [] with []°-> () | _ -> ();; 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/bug-by-vincent-balat.ml: -------------------------------------------------------------------------------- 1 | fun a -> x <- !x + 1; x <- !x + 2 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/bug-camlp4o-benjamin-monate.ml: -------------------------------------------------------------------------------- 1 | type t = A of t | B ;; 2 | let f = function A A B -> B | B | A B | A (A _) -> B ;; 3 | 4 | exception True 5 | let qexists f q = 6 | try 7 | Queue.iter (fun v -> if f v then raise True) q; 8 | false 9 | with True -> true 10 | 11 | type u = True | False 12 | let g x = function | True -> () | False -> () 13 | 14 | type v = [`True | `False] 15 | let h x = function | `True -> () | `False -> () 16 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/bug-camlp4o-constr-arity-expr.ml: -------------------------------------------------------------------------------- 1 | (* Some Some Some None;; *) 2 | (* ((Some None) None) None;; *) 3 | ((Some) None);; 4 | (* ((Some Some) Some) None;; *) 5 | type t = A of int * int * int;; 6 | A (1, 2, 3);; 7 | (A) (1, 2, 3);; 8 | (A (1, 2)) 3;; 9 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/bug_escaping_quot.ml: -------------------------------------------------------------------------------- 1 | open Camlp4.PreCast;; 2 | Camlp4_config.antiquotations := true;; 3 | let expand_my_quot_expr _loc _loc_name_opt quotation_contents = 4 | Printf.eprintf "%S\n%!" quotation_contents; 5 | <:expr< dummy >> 6 | ;; 7 | Syntax.Quotation.add "my" Syntax.Quotation.DynAst.expr_tag expand_my_quot_expr;; 8 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/chars.ml: -------------------------------------------------------------------------------- 1 | '"' 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/curry-constr.ml: -------------------------------------------------------------------------------- 1 | type t = A of int 2 | type u = B of t 3 | let f = function B A x -> x 4 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/default_quotation.ml: -------------------------------------------------------------------------------- 1 | #default_quotation "expr"; 2 | open Camlp4.PreCast; 3 | fun [ << $x$ - $y$ >> when x = y -> << 0 >> 4 | | e -> e ]; 5 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/exception-with-eqn-bug.ml: -------------------------------------------------------------------------------- 1 | exception Foo of string = Bar 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/external.ml: -------------------------------------------------------------------------------- 1 | external f : 'a -> 'b = "%identity"; 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/fun.ml: -------------------------------------------------------------------------------- 1 | value f = fun []; 2 | value f = fun [ [] -> fun [ 4 -> () ] ]; 3 | value f = fun []; 4 | value f = fun []; 5 | value f = fun []; 6 | value f = g x y; 7 | value f = (g x) y; 8 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/gen_map.ml: -------------------------------------------------------------------------------- 1 | type t = 2 | A of int * t * t 3 | | B of int list 4 | | C of option t 5 | 6 | module Map = struct 7 | module T = Camlp4Filters.GenerateMap.Generated 8 | end 9 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/gram-list.ml: -------------------------------------------------------------------------------- 1 | open Camlp4.PreCast; 2 | module G = MakeGram Lexer; 3 | value main = G.Entry.mk "main"; 4 | EXTEND G 5 | GLOBAL: main; 6 | main: 7 | [ [ l = LIST1 ident -> l ] ]; 8 | ident: 9 | [ [ `LIDENT s -> s ] ]; 10 | END; 11 | let f = Sys.argv.(1) in 12 | Format.printf "%d@." 13 | (List.length (G.parse main (Loc.mk f) (Stream.of_channel (open_in f)))); 14 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/gram.ml: -------------------------------------------------------------------------------- 1 | EXTEND G expr: [[ l = LIST0 STRING -> l ]]; END; 2 | EXTEND G expr: [[ l = LIST0 [ x = STRING -> x ] -> l ]]; END; 3 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/if.ml: -------------------------------------------------------------------------------- 1 | let x = if x then a else b in x 2 | 3 | let x = if StringSet.mem "*" sections then a else b in x 4 | 5 | let x = 6 | if StringSet.mem "*" sections then fun _ -> true else 7 | fun x -> StringSet.mem x sections 8 | in x 9 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/label.ml: -------------------------------------------------------------------------------- 1 | value f ~a:_ ?b:_ = (); 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/loc-bug.ml: -------------------------------------------------------------------------------- 1 | #default_quotation "expr";; 2 | Lwt.return 3 | << 3 + >> 4 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/macrotest.mli: -------------------------------------------------------------------------------- 1 | DEFINE A; 2 | DEFINE B; 3 | 4 | IFDEF A THEN 5 | value a_should_be_present : int; 6 | ENDIF; 7 | 8 | IFNDEF C THEN 9 | value b_should_be_present : int; 10 | ENDIF; 11 | 12 | IFNDEF C THEN 13 | value c_should_be_present : int; 14 | ELSE 15 | value a_should_NOT_be_present : int; 16 | END; 17 | 18 | IFDEF C THEN 19 | value b_should_NOT_be_present : int; 20 | ELSE 21 | value d_should_be_present : int; 22 | value e_should_be_present : int; 23 | ENDIF; 24 | 25 | value f_should_be_present : int; 26 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/macrotest2.ml: -------------------------------------------------------------------------------- 1 | IFNDEF UNDEFINED_VARIABLE THEN 2 | DEFINE SQUARE (x) = x * x ;; 3 | DEFINE DOUBLE_SQUARE (x) = (SQUARE x) * 2 ;; 4 | END;; 5 | 6 | Printf.printf "%d\n" (DOUBLE_SQUARE(42)) ;; 7 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/macrotest3.ml: -------------------------------------------------------------------------------- 1 | IFNDEF UNDEFINED_VARIABLE THEN 2 | DEFINE UNDEFINED_VARIABLE 3 | 4 | IFDEF UNDEFINED_VARIABLE THEN 5 | DEFINE SQUARE (x) = x * x ;; 6 | DEFINE DOUBLE_SQUARE (x) = (SQUARE x) * 2 ;; 7 | END 8 | END;; 9 | 10 | Printf.printf "%d\n" (DOUBLE_SQUARE(42)) ;; 11 | 12 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/make_extend.ml: -------------------------------------------------------------------------------- 1 | <:expr< EXTEND G expr: [[ "foo" -> <:expr< foo >> ]]; END >>; 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/match.ml: -------------------------------------------------------------------------------- 1 | let x = 2 | match y with 3 | | A z -> z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z z 4 | | B l -> 5 | (match l with 6 | | [] -> () 7 | | x::xs -> p x; self xs) 8 | | C -> () 9 | in x 10 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/match_parser.ml: -------------------------------------------------------------------------------- 1 | open Camlp4.PreCast; 2 | 3 | let _loc = Loc.ghost in 4 | let e = <:expr< parser [: `"a" :] -> t >> in 5 | let a = 6 | match e with 7 | [ <:expr< parser [: `$str:x$ :] -> t >> -> x 8 | | _ -> assert False ] 9 | in Format.printf "a: %S@." a; 10 | 11 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/meta_multi_term.ml: -------------------------------------------------------------------------------- 1 | open Camlp4.PreCast; 2 | value _loc = Loc.ghost; 3 | 4 | module Term = struct 5 | type patt = 6 | [ PApp of patt and patt 7 | | PAny 8 | | PVar of string 9 | | POlb of string and expr ] 10 | and expr = 11 | [ EApp of expr and expr 12 | | EVar of string 13 | | ELam of patt and expr ]; 14 | end; 15 | 16 | module MetaTerm = MetaGenerator Term; 17 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/metalib.ml: -------------------------------------------------------------------------------- 1 | #load "camlp4of.cma";; 2 | open Camlp4.PreCast;; 3 | module M = Ast.Meta.Make(Ast.Meta.MetaGhostLoc);; 4 | let ghost = Loc.ghost;; 5 | M.Expr.meta_ctyp ghost <:ctyp@ghost< int >>;; 6 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/mod.ml: -------------------------------------------------------------------------------- 1 | module type S = sig type t end 2 | module F (A : S) = struct 3 | type t2 = A.t 4 | module A = A 5 | end 6 | 7 | module A = struct type t = int end 8 | 9 | module type S3 = sig 10 | module M : S 11 | end 12 | 13 | module type S2 = S with type t = F(A).t2 14 | 15 | module type S4 = S3 with module M = F(A).A 16 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/mod2.ml: -------------------------------------------------------------------------------- 1 | module type S = sig type t = 'a; end; 2 | module F (A : S) = struct 3 | type t2 = A.t; 4 | end; 5 | 6 | module A = struct type t = int; end; 7 | 8 | module type S2 = S with type t = (F A).t2; 9 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/operators.ml: -------------------------------------------------------------------------------- 1 | let _ : int = 42 2 | let (+) = M.(+) 3 | let (+) = M.(+) in 42 4 | let (+) : int -> int -> int = (+) 5 | let (+) : int -> int -> int = (+) in 42 6 | let None = None 7 | let None : int option = None 8 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/operators.mli: -------------------------------------------------------------------------------- 1 | val (+) : int -> int -> int 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/original_syntax.ml: -------------------------------------------------------------------------------- 1 | fun x when x <> 0 -> x / 42 2 | ;; 3 | object val virtual mutable x : int val mutable virtual y : int end 4 | ;; 5 | - !r 6 | ;; 7 | ! -r 8 | ;; 9 | -32 10 | ;; 11 | - - 32 12 | ;; 13 | !(r.b) 14 | ;; 15 | (!r).b = !r.b 16 | ;; 17 | let l : (unit -> int) list = [(fun _ -> 42); (fun _ -> 42)] 18 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/pp_let_in.ml: -------------------------------------------------------------------------------- 1 | let i = "toto" in do { (let i = 42 in print_int i); print_string i }; 2 | let i = "toto" in do { print_string i; let i = 42 in print_int i; print_int i }; 3 | let i = "toto" in do { 4 | (let i = 42 in print_int i); 5 | let i = i ^ i; 6 | let i = i ^ i; 7 | print_string i; 8 | print_string i; 9 | let i = i ^ i; 10 | print_string i }; 11 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/pp_let_in2.ml: -------------------------------------------------------------------------------- 1 | let i = "toto" in ((let i = 42 in print_int i); print_string i) 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/pr4314.ml: -------------------------------------------------------------------------------- 1 | (int_of_string "1" : unit); 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/pr4357.ml: -------------------------------------------------------------------------------- 1 | open Camlp4.PreCast 2 | 3 | let sample_expr _loc _loc_name s = 4 | Printf.eprintf "file=%s line=%d offset=%d bol=%d\n%!" 5 | (Loc.file_name _loc) 6 | (Loc.start_line _loc) 7 | (Loc.start_off _loc) 8 | (Loc.start_bol _loc); 9 | <:expr< $lid:s$ >> 10 | ;; 11 | 12 | Quotation.add 13 | "sample" 14 | Syntax.Quotation.DynAst.expr_tag 15 | sample_expr 16 | ;; 17 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/pr4357sample.ml: -------------------------------------------------------------------------------- 1 | let u = "Hello";; 2 | let s = <:sample>;; 3 | print_string s 4 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/pr4357sample2.ml: -------------------------------------------------------------------------------- 1 | #default_quotation "sample";; 2 | let u = "Hello";; 3 | let s = <>;; 4 | let s = <:sample>;; 5 | print_string s 6 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/rec.ml: -------------------------------------------------------------------------------- 1 | (* rec.ml *) 2 | value rec x = 42; 3 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/simplify.ml: -------------------------------------------------------------------------------- 1 | open Camlp4.PreCast 2 | 3 | let simplify = 4 | object 5 | inherit Ast.map as super 6 | method expr e = 7 | match super#expr e with 8 | | <:expr< $x$ + 0 >> | <:expr< 0 + $x$ >> -> x 9 | | x -> x 10 | end 11 | in AstFilters.register_str_item_filter simplify#str_item 12 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/simplify_r.ml: -------------------------------------------------------------------------------- 1 | open Camlp4.PreCast; 2 | 3 | let simplify = 4 | object 5 | inherit Ast.map as super; 6 | method expr e = 7 | match super#expr e with 8 | [ <:expr< $x$ + 0 >> | <:expr< 0 + $x$ >> -> x 9 | | x -> x ]; 10 | end 11 | in AstFilters.register_str_item_filter simplify#str_item; 12 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/stream-parser-bug.ml: -------------------------------------------------------------------------------- 1 | let foo = parser 2 | | [< '42; ps >] -> 3 | let ps = ps + 42 in 4 | type_phrases ps 5 | | [< >] -> [< >] 6 | 7 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/string.ml: -------------------------------------------------------------------------------- 1 | "abc"; 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/superfluous.ml: -------------------------------------------------------------------------------- 1 | open Camlp4.PreCast;; 2 | open Syntax;; 3 | 4 | let _loc = Loc.ghost;; 5 | let st = <:str_item< >>;; 6 | let e = <:expr< 1 >> 7 | let bi = <:binding< x = 0 >>;; 8 | 9 | (* none of these holds due to superfluous StSem and StNil *) 10 | assert (Ast.StSem (_loc, st, st) = <:str_item< $st$ $st$ >>);; 11 | assert (Ast.StExp (_loc, e) = <:str_item< $exp:e$ >>);; 12 | assert (Ast.StVal (_loc, bi) = <:str_item< let $bi$ >>);; 13 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/transform-examples.ml: -------------------------------------------------------------------------------- 1 | <:expr< $x$ + $y$ - $z$ >> -> <:expr< plus_minus $x$ $y$ $z$ >> 2 | 3 | << List.rev (List.rev $l$) >> -> l 4 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/try.ml: -------------------------------------------------------------------------------- 1 | try 2 | let f = Sys.getenv "CAMLP4_DEBUG_FILE" 3 | in 4 | foo bar foo bar foo bar foo bar foo bar foo bar foo bar foo bar foo bar foo bar foo bar foo bar 5 | with Not_found -> stderr 6 | 7 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/tuple_as_retval.ml: -------------------------------------------------------------------------------- 1 | EXTEND Gram 2 | abc: [ [ (x,y) = foo -> x+y ] ]; 3 | END; 4 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/type.ml: -------------------------------------------------------------------------------- 1 | type t = [ A of int | B of t ]; 2 | type t2 = [ A of int | B of t ]; 3 | type t3 = [ A of int | B of t ]; 4 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/unit.ml: -------------------------------------------------------------------------------- 1 | type t1 = ();; 2 | type t2 = unit;; 3 | let x : t1 = ();; 4 | let y : t2 = ();; 5 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/use.ml: -------------------------------------------------------------------------------- 1 | (* use.ml *) 2 | #use "test/fixtures/rec.ml"; 3 | (* value use *) 4 | value use = 3; 5 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/where.o.ml: -------------------------------------------------------------------------------- 1 | let where = 42 2 | -------------------------------------------------------------------------------- /camlp4/test/fixtures/where.r.ml: -------------------------------------------------------------------------------- 1 | x where x = 42; 2 | -------------------------------------------------------------------------------- /camlp4/unmaintained/compile/.cvsignore: -------------------------------------------------------------------------------- 1 | *.fast 2 | *.fast.opt 3 | o_fast.ml 4 | pa_o_fast.ml 5 | -------------------------------------------------------------------------------- /camlp4/unmaintained/compile/.depend: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/camlp4/unmaintained/compile/.depend -------------------------------------------------------------------------------- /camlp4/unmaintained/etc/.cvsignore: -------------------------------------------------------------------------------- 1 | *.cm[oia] 2 | camlp4o 3 | camlp4sch 4 | camlp4o.opt 5 | version.sh 6 | mkcamlp4.sh 7 | mkcamlp4.mpw 8 | -------------------------------------------------------------------------------- /camlp4/unmaintained/etc/.depend: -------------------------------------------------------------------------------- 1 | parserify.cmo: parserify.cmi 2 | parserify.cmx: parserify.cmi 3 | pr_op_main.cmo: parserify.cmi 4 | pr_op_main.cmx: parserify.cmx 5 | pr_rp_main.cmo: parserify.cmi 6 | pr_rp_main.cmx: parserify.cmx 7 | -------------------------------------------------------------------------------- /camlp4/unmaintained/etc/parserify.mli: -------------------------------------------------------------------------------- 1 | (* camlp4r *) 2 | 3 | 4 | type spc = 5 | [ SPCterm of (MLast.patt * option MLast.expr) 6 | | SPCnterm of MLast.patt and MLast.expr 7 | | SPCsterm of MLast.patt ] 8 | ; 9 | 10 | value parser_of_expr : 11 | MLast.expr -> 12 | list (list (spc * option MLast.expr) * option MLast.patt * MLast.expr); 13 | -------------------------------------------------------------------------------- /camlp4/unmaintained/format/.depend: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/camlp4/unmaintained/format/.depend -------------------------------------------------------------------------------- /camlp4/unmaintained/lefteval/.depend: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/camlp4/unmaintained/lefteval/.depend -------------------------------------------------------------------------------- /camlp4/unmaintained/lib/.cvsignore: -------------------------------------------------------------------------------- 1 | *.cm[oiax] 2 | *.cmxa 3 | *.lib 4 | -------------------------------------------------------------------------------- /camlp4/unmaintained/lib/.depend: -------------------------------------------------------------------------------- 1 | debug.cmo: debug.cmi 2 | debug.cmx: debug.cmi 3 | extfun.cmo: extfun.cmi 4 | extfun.cmx: extfun.cmi 5 | fstream.cmo: fstream.cmi 6 | fstream.cmx: fstream.cmi 7 | grammar.cmo: token.cmi plexer.cmi loc.cmi 8 | grammar.cmx: token.cmx plexer.cmi loc.cmx 9 | loc.cmo: loc.cmi 10 | loc.cmx: loc.cmi 11 | token.cmo: loc.cmi token.cmi 12 | token.cmx: loc.cmx token.cmi 13 | plexer.cmi: token.cmi loc.cmi 14 | token.cmi: loc.cmi 15 | -------------------------------------------------------------------------------- /camlp4/unmaintained/ocpp/.cvsignore: -------------------------------------------------------------------------------- 1 | *.cm[oia] 2 | ocpp 3 | crc.ml 4 | -------------------------------------------------------------------------------- /camlp4/unmaintained/ocpp/.depend: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/camlp4/unmaintained/ocpp/.depend -------------------------------------------------------------------------------- /camlp4/unmaintained/odyl/.cvsignore: -------------------------------------------------------------------------------- 1 | *.cm[oia] 2 | odyl 3 | *.lib 4 | odyl_config.ml 5 | -------------------------------------------------------------------------------- /camlp4/unmaintained/odyl/.depend: -------------------------------------------------------------------------------- 1 | odyl.cmo: odyl_main.cmi odyl_config.cmo 2 | odyl.cmx: odyl_main.cmx odyl_config.cmx 3 | odyl_main.cmo: odyl_config.cmo odyl_main.cmi 4 | odyl_main.cmx: odyl_config.cmx odyl_main.cmi 5 | -------------------------------------------------------------------------------- /camlp4/unmaintained/odyl/odyl_main.mli: -------------------------------------------------------------------------------- 1 | (* camlp4r *) 2 | 3 | 4 | exception Error of string and string; 5 | 6 | value nolib : ref bool; 7 | value initialized : ref bool; 8 | value path : ref (list string); 9 | value loadfile : string -> unit; 10 | value directory : string -> unit; 11 | 12 | value go : ref (unit -> unit); 13 | value name : ref string; 14 | -------------------------------------------------------------------------------- /camlp4/unmaintained/olabl/.depend: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/camlp4/unmaintained/olabl/.depend -------------------------------------------------------------------------------- /camlp4/unmaintained/olabl/pa_olabl.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/camlp4/unmaintained/olabl/pa_olabl.ml -------------------------------------------------------------------------------- /camlp4/unmaintained/scheme/.depend: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/camlp4/unmaintained/scheme/.depend -------------------------------------------------------------------------------- /camlp4/unmaintained/sml/.depend: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/camlp4/unmaintained/sml/.depend -------------------------------------------------------------------------------- /config/.cvsignore: -------------------------------------------------------------------------------- 1 | m.h 2 | s.h 3 | Makefile 4 | config.sh 5 | -------------------------------------------------------------------------------- /config/auto-aux/.cvsignore: -------------------------------------------------------------------------------- 1 | camlp4_config.ml 2 | -------------------------------------------------------------------------------- /config/auto-aux/runtest: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | if test "$verbose" = yes; then 3 | echo "runtest: $cc -o tst $* $cclibs" >&2 4 | $cc -o tst $* $cclibs || exit 100 5 | else 6 | $cc -o tst $* $cclibs 2> /dev/null || exit 100 7 | fi 8 | exec ./tst 9 | -------------------------------------------------------------------------------- /config/auto-aux/searchpath: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Find a program in the path 3 | 4 | IFS=':' 5 | for dir in $PATH; do 6 | if test -z "$dir"; then dir=.; fi 7 | if test -f $dir/$1; then exit 0; fi 8 | done 9 | exit 1 10 | -------------------------------------------------------------------------------- /config/auto-aux/sharpbang: -------------------------------------------------------------------------------- 1 | #! /bin/cat 2 | exit 1 3 | -------------------------------------------------------------------------------- /config/auto-aux/sharpbang2: -------------------------------------------------------------------------------- 1 | #! /usr/bin/cat 2 | exit 1 3 | -------------------------------------------------------------------------------- /config/auto-aux/solaris-ld: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Determine if gcc calls the Solaris ld or the GNU ld 3 | # Exit code is 0 for Solaris ld, 1 for GNU ld 4 | 5 | echo "int main() { return 0; }" > hasgot.c 6 | $cc -v -o tst hasgot.c 2>&1 | grep -s '^ld:' > /dev/null 7 | exit $? 8 | -------------------------------------------------------------------------------- /config/auto-aux/tclversion.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | 5 | main () 6 | { 7 | puts(TCL_VERSION); 8 | } 9 | -------------------------------------------------------------------------------- /config/auto-aux/trycompile: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | if test "$verbose" = yes; then 3 | echo "trycompile: $cc -o tst $* $cclibs" >&2 4 | $cc -o tst $* $cclibs || exit 100 5 | else 6 | $cc -o tst $* $cclibs 2> /dev/null || exit 100 7 | fi 8 | -------------------------------------------------------------------------------- /debugger/.cvsignore: -------------------------------------------------------------------------------- 1 | lexer.ml 2 | parser.ml 3 | parser.mli 4 | ocamldebug 5 | dynlink.ml 6 | dynlink.mli 7 | -------------------------------------------------------------------------------- /debugger/question.mli: -------------------------------------------------------------------------------- 1 | (* Ask user a yes or no question. *) 2 | val yes_or_no : string -> bool 3 | -------------------------------------------------------------------------------- /driver/ocamlcomp.sh.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | topdir=`dirname $0` 4 | 5 | exec @compiler@ -nostdlib -I $topdir/stdlib "$@" 6 | -------------------------------------------------------------------------------- /emacs/.cvsignore: -------------------------------------------------------------------------------- 1 | ocamltags 2 | -------------------------------------------------------------------------------- /lex/.cvsignore: -------------------------------------------------------------------------------- 1 | parser.ml 2 | parser.mli 3 | lexer.ml 4 | ocamllex 5 | ocamllex.opt 6 | parser.output 7 | -------------------------------------------------------------------------------- /ocamlbuild/AUTHORS: -------------------------------------------------------------------------------- 1 | Nicolas Pouillard 2 | Berke Durak 3 | -------------------------------------------------------------------------------- /ocamlbuild/_tags: -------------------------------------------------------------------------------- 1 | # OCamlbuild tags file 2 | true: debug 3 | <*.ml> or <*.mli>: warn_L, warn_R, warn_Z, annot 4 | "discard_printf.ml": rectypes 5 | "ocamlbuildlib.cma" or "ocamlbuildlightlib.cma": linkall 6 | <*.byte> or <*.native> or <*.top>: use_unix 7 | "ocamlbuildlight.byte": -use_unix 8 | <*.cmx>: for-pack(Ocamlbuild_pack) 9 | <{ocamlbuild_{pack,unix_plugin,plugin,executor},ppcache}{,.p}.cmx>: -for-pack(Ocamlbuild_pack) 10 | "doc": not_hygienic 11 | -------------------------------------------------------------------------------- /ocamlbuild/examples/example1/hello.ml: -------------------------------------------------------------------------------- 1 | let _ = 2 | Printf.printf "Hello, %s ! My name is %s\n" 3 | (if Array.length Sys.argv > 1 then Sys.argv.(1) else "stranger") 4 | Sys.argv.(0) 5 | ;; 6 | -------------------------------------------------------------------------------- /ocamlbuild/examples/example2/greet.ml: -------------------------------------------------------------------------------- 1 | type how = Nicely | Badly;; 2 | 3 | let greet how who = 4 | match how with Nicely -> Printf.printf "Hello, %s !\n" who 5 | | Badly -> Printf.printf "Oh, here is that %s again.\n" who 6 | ;; 7 | -------------------------------------------------------------------------------- /ocamlbuild/examples/example2/hello.ml: -------------------------------------------------------------------------------- 1 | open Greet 2 | 3 | let _ = 4 | let name = 5 | if Array.length Sys.argv > 1 then 6 | Sys.argv.(1) 7 | else 8 | "stranger" 9 | in 10 | greet 11 | (if name = "Caesar" then Nicely else Badly) 12 | name; 13 | Printf.printf "My name is %s\n" Sys.argv.(0) 14 | ;; 15 | -------------------------------------------------------------------------------- /ocamlbuild/examples/example3/epoch.ml: -------------------------------------------------------------------------------- 1 | let _ = 2 | let s = Num.num_of_string (Printf.sprintf "%.0f" (Unix.gettimeofday ())) in 3 | let ps = Num.mult_num (Num.num_of_string "1000000000000") s in 4 | Printf.printf "%s picoseconds have passed since January 1st, 1970.\n" 5 | (Num.string_of_num ps) 6 | ;; 7 | -------------------------------------------------------------------------------- /ocamlbuild/manual/.cvsignore: -------------------------------------------------------------------------------- 1 | *.aux 2 | *.haux 3 | *.html 4 | *.htoc 5 | *.log 6 | *.pdf 7 | -------------------------------------------------------------------------------- /ocamlbuild/manual/Makefile: -------------------------------------------------------------------------------- 1 | # Makefile 2 | 3 | all: manual.pdf manual.html 4 | 5 | %.pdf: %.tex 6 | pdflatex $< 7 | pdflatex $< 8 | 9 | %.html: %.tex manual.hva 10 | hevea -fix -O manual.hva $< 11 | 12 | .PHONY: clean 13 | 14 | clean: 15 | rm -f *.pdf *.log *.aux *.ps *.dvi manual.h{tml,aux,toc} 16 | -------------------------------------------------------------------------------- /ocamlbuild/manual/manual.hva: -------------------------------------------------------------------------------- 1 | \newcommand{\mathscr}[1]{{\mathcal{#1}}} -------------------------------------------------------------------------------- /ocamlbuild/ocamlbuild.mltop: -------------------------------------------------------------------------------- 1 | Ocamlbuild_pack 2 | Ocamlbuild_plugin 3 | Ocamlbuild_unix_plugin 4 | -------------------------------------------------------------------------------- /ocamlbuild/ocamlbuild_plugin.mli: -------------------------------------------------------------------------------- 1 | include Ocamlbuild_pack.Signatures.PLUGIN 2 | with module Pathname = Ocamlbuild_pack.Pathname 3 | and module Outcome = Ocamlbuild_pack.My_std.Outcome 4 | and module Tags = Ocamlbuild_pack.Tags 5 | and module Command = Ocamlbuild_pack.Command 6 | -------------------------------------------------------------------------------- /ocamlbuild/ocamlbuild_where.ml: -------------------------------------------------------------------------------- 1 | let bindir = ref Ocamlbuild_Myocamlbuild_config.bindir;; 2 | let libdir = ref begin 3 | Filename.concat 4 | (try Sys.getenv "OCAMLLIB" 5 | with Not_found -> Ocamlbuild_Myocamlbuild_config.libdir) 6 | "ocamlbuild" 7 | end;; 8 | -------------------------------------------------------------------------------- /ocamlbuild/ocamlbuildlib.mllib: -------------------------------------------------------------------------------- 1 | Ocamlbuild_pack 2 | Ocamlbuild_plugin 3 | Ocamlbuild_unix_plugin 4 | Ocamlbuild_executor 5 | -------------------------------------------------------------------------------- /ocamlbuild/ocamlbuildlightlib.mllib: -------------------------------------------------------------------------------- 1 | Ocamlbuild_pack 2 | Ocamlbuild_plugin 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test1/foo.ml: -------------------------------------------------------------------------------- 1 | module MA1 = A1 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test10/dbdi: -------------------------------------------------------------------------------- 1 | #load "discard_printf.cmo";; 2 | #load "debug.cmo";; 3 | #load "unix.cma";; 4 | #load "str.cma";; 5 | #load "my_unix.cmo";; 6 | #load "bool.cmo";; 7 | #load "glob_ast.cmo";; 8 | #load "glob_lexer.cmo";; 9 | #load "glob.cmo";; 10 | #load "lexers.cmo";; 11 | #load "my_std.cmo";; 12 | #load "tags.cmo";; 13 | -------------------------------------------------------------------------------- /ocamlbuild/test/test10/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -e 3 | set -x 4 | cd `dirname $0`/../.. 5 | ./_build/ocamlbuild.native -quiet -build-dir _buildtest -no-links test/test9/testglob.native 6 | ./_buildtest/test/test9/testglob.native 7 | -------------------------------------------------------------------------------- /ocamlbuild/test/test11/_tags: -------------------------------------------------------------------------------- 1 | # a comment 2 | "a/aa.byte" or "a/aa.native": use_libb 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test11/a/aa.ml: -------------------------------------------------------------------------------- 1 | let bar = 3 + List.length Bb.foo 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test11/a/aa.mli: -------------------------------------------------------------------------------- 1 | val bar : int 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test11/b/bb.ml: -------------------------------------------------------------------------------- 1 | let foo = [2.2] 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test11/b/libb.mllib: -------------------------------------------------------------------------------- 1 | Bb 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test11/myocamlbuild.ml: -------------------------------------------------------------------------------- 1 | open Ocamlbuild_plugin;; 2 | dispatch begin function 3 | | After_rules -> ocaml_lib "b/libb" 4 | | _ -> () 5 | end 6 | -------------------------------------------------------------------------------- /ocamlbuild/test/test11/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | cd `dirname $0` 3 | set -e 4 | set -x 5 | CMDOTPS="" # -- command args 6 | BUILD="../../_build/ocamlbuild.native -I a -I b aa.byte aa.native -no-skip -classic-display $@" 7 | BUILD1="$BUILD $CMDOPTS" 8 | BUILD2="$BUILD -verbose 0 -nothing-should-be-rebuilt $CMDOPTS" 9 | rm -rf _build 10 | $BUILD1 11 | echo looks if libs are there 12 | ls _build/b/libb.cma _build/b/libb.cmxa _build/b/libb.a 13 | $BUILD2 14 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/_tags: -------------------------------------------------------------------------------- 1 | "vivi.ml": camlp4o 2 | 3 | # , some_useless_tag, \ more_useless_tags 4 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/tata.ml: -------------------------------------------------------------------------------- 1 | let tata = "TATA2" 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/tata.mli: -------------------------------------------------------------------------------- 1 | (* a comment *) 2 | val tata : string 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | cd `dirname $0` 3 | set -e 4 | set -x 5 | CMDOPTS="-- -help" 6 | BUILD="../../_build/ocamlbuild.native toto.byte toto.native -no-skip -classic-display $@" 7 | BUILD1="$BUILD $CMDOPTS" 8 | BUILD2="$BUILD -verbose 0 -nothing-should-be-rebuilt $CMDOPTS" 9 | rm -rf _build 10 | cp vivi1.ml vivi.ml 11 | $BUILD1 12 | $BUILD2 13 | cp vivi2.ml vivi.ml 14 | $BUILD1 15 | $BUILD2 16 | cp vivi3.ml vivi.ml 17 | $BUILD1 18 | $BUILD2 19 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/titi.ml: -------------------------------------------------------------------------------- 1 | let titi = [] 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/toto.ml: -------------------------------------------------------------------------------- 1 | let i = Tutu.tutu + 10 2 | let s = Tata.tata ^ ".ml" 3 | let l = 3 :: Titi.titi 4 | let () = Format.printf "toto.native: %s: Hello world!!!@." Sys.argv.(0) 5 | let () = Format.printf "Tutu.tutu => %d@.Tata.tata => %S@." Tutu.tutu Tata.tata 6 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/tutu.ml: -------------------------------------------------------------------------------- 1 | let tutu = (Array.length Vivi.vivi : Tyty.t) 2 | let tutu' = 2.0 +. float_of_int tutu 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/tutu.mli: -------------------------------------------------------------------------------- 1 | (* a comment *) 2 | val tutu : int 3 | val tutu' : float 4 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/tyty.mli: -------------------------------------------------------------------------------- 1 | type t = int 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/vivi1.ml: -------------------------------------------------------------------------------- 1 | let rec p i = [< '1; '2; p (i + 1) >] 2 | let vivi = [|2|] 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/vivi2.ml: -------------------------------------------------------------------------------- 1 | let rec p i = [< '1; '2; p (i + 1) >] 2 | let vivi = [|3|] 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test2/vivi3.ml: -------------------------------------------------------------------------------- 1 | let rec p i = [< '1; '2; p (i + 1) >] 2 | let vivi = [|2.1; 1.1|] 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/_tags: -------------------------------------------------------------------------------- 1 | "a.byte" or "a.native": use_unix 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/a.ml: -------------------------------------------------------------------------------- 1 | module X = B 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/a.mli: -------------------------------------------------------------------------------- 1 | (* Nothing *) 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/b.ml: -------------------------------------------------------------------------------- 1 | module X = C 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/b.mli: -------------------------------------------------------------------------------- 1 | (* nothing *) 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/c.ml: -------------------------------------------------------------------------------- 1 | module X = D 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/c.mli: -------------------------------------------------------------------------------- 1 | (* nothing *) 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/d.ml: -------------------------------------------------------------------------------- 1 | module X = E 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/d.mli: -------------------------------------------------------------------------------- 1 | (* nothing *) 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/e.ml: -------------------------------------------------------------------------------- 1 | module X = F 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/e.mli: -------------------------------------------------------------------------------- 1 | (* nothing *) 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/f.ml: -------------------------------------------------------------------------------- 1 | (* nothing *) 2 | let _ = Unix.stat 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/f.mli: -------------------------------------------------------------------------------- 1 | (* nothing *) 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/proj.odocl: -------------------------------------------------------------------------------- 1 | A B C D E F 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test3/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | cd `dirname $0` 3 | set -e 4 | set -x 5 | CMDOTPS="" # -- command args 6 | BUILD="../../_build/ocamlbuild.native a.byte a.native proj.docdir/index.html -no-skip -classic-display $@" 7 | BUILD1="$BUILD $CMDOPTS" 8 | BUILD2="$BUILD -verbose 0 -nothing-should-be-rebuilt $CMDOPTS" 9 | rm -rf _build 10 | $BUILD1 11 | $BUILD2 12 | -------------------------------------------------------------------------------- /ocamlbuild/test/test4/_tags: -------------------------------------------------------------------------------- 1 | # a comment 2 | "a/aa.byte" or "a/aa.native": use_str 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test4/a/aa.ml: -------------------------------------------------------------------------------- 1 | let bar = 3 + List.length Bb.foo 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test4/a/aa.mli: -------------------------------------------------------------------------------- 1 | val bar : int 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test4/b/bb.ml: -------------------------------------------------------------------------------- 1 | let r = Str.regexp "r" 2 | let foo = [2.2] 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test4/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | cd `dirname $0` 3 | set -e 4 | set -x 5 | CMDOTPS="" # -- command args 6 | BUILD="../../_build/ocamlbuild.native -I a -I b aa.byte aa.native -no-skip -classic-display $@" 7 | BUILD1="$BUILD $CMDOPTS" 8 | BUILD2="$BUILD -verbose 0 -nothing-should-be-rebuilt $CMDOPTS" 9 | rm -rf _build 10 | $BUILD1 11 | $BUILD2 12 | -------------------------------------------------------------------------------- /ocamlbuild/test/test5/_tags: -------------------------------------------------------------------------------- 1 | "a.cmx" or "b.cmx": for-pack(C) 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test5/a.ml: -------------------------------------------------------------------------------- 1 | let a = 42 + Stack.stack 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test5/a.mli: -------------------------------------------------------------------------------- 1 | val a : int 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test5/b.ml: -------------------------------------------------------------------------------- 1 | let b = A.a + 1 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test5/c.mlpack: -------------------------------------------------------------------------------- 1 | A B 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test5/d.ml: -------------------------------------------------------------------------------- 1 | Format.printf "C.B.b = %d@." C.B.b 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test5/stack.ml: -------------------------------------------------------------------------------- 1 | let stack = 42 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test5/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | cd `dirname $0` 3 | set -e 4 | set -x 5 | CMDOPTS="" # -- command args 6 | BUILD="../../_build/ocamlbuild.native d.byte d.native -no-skip -classic-display $@" 7 | BUILD1="$BUILD $CMDOPTS" 8 | BUILD2="$BUILD -verbose 0 -nothing-should-be-rebuilt $CMDOPTS" 9 | rm -rf _build 10 | $BUILD1 11 | $BUILD2 12 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/a.ml: -------------------------------------------------------------------------------- 1 | let a = B.b 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/a.mli: -------------------------------------------------------------------------------- 1 | val a : 'a -> 'a 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/b.ml: -------------------------------------------------------------------------------- 1 | let b = D.d 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/b.mli: -------------------------------------------------------------------------------- 1 | val b : 'a -> 'a 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/b.mli.v1: -------------------------------------------------------------------------------- 1 | val b : 'a -> 'a 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/b.mli.v2: -------------------------------------------------------------------------------- 1 | .... 2 | val b : 'a -> 'a 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/d.ml: -------------------------------------------------------------------------------- 1 | type t 2 | let d x = x 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/d.mli: -------------------------------------------------------------------------------- 1 | val d : 'a -> 'a 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/d.mli.v1: -------------------------------------------------------------------------------- 1 | type t 2 | val d : 'a -> 'a 3 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/d.mli.v2: -------------------------------------------------------------------------------- 1 | val d : 'a -> 'a 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/main.ml: -------------------------------------------------------------------------------- 1 | A.a 2. +. D.d 1. 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test6/main.mli: -------------------------------------------------------------------------------- 1 | (* nothing *) 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/_tags: -------------------------------------------------------------------------------- 1 | "main.byte": my_cool_plugin 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/aa.ml: -------------------------------------------------------------------------------- 1 | let aa = "aa" 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/bb.mli: -------------------------------------------------------------------------------- 1 | val bb : int 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/bb1.ml: -------------------------------------------------------------------------------- 1 | let bb = 43 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/bb2.ml: -------------------------------------------------------------------------------- 1 | let bb = 43 2 | let f x = x + 1 3 | let () = incr (ref 0) 4 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/bb3.ml: -------------------------------------------------------------------------------- 1 | let bb = 43 2 | let f x = x + 1 3 | let () = incr (ref 1) 4 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/bbcc.mllib: -------------------------------------------------------------------------------- 1 | Bb Cc 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/c2.ml: -------------------------------------------------------------------------------- 1 | let c2 = 12 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/c2.mli: -------------------------------------------------------------------------------- 1 | val c2 : int 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/c3.ml: -------------------------------------------------------------------------------- 1 | let c3 = Bb.bb + 13 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/cc.ml: -------------------------------------------------------------------------------- 1 | let cc = (String.length Aa.aa) + Bb.bb + C2.c2 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/cool_plugin.ml: -------------------------------------------------------------------------------- 1 | print_endline "I am a cool plugin" 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/main.ml: -------------------------------------------------------------------------------- 1 | let main = String.length Aa.aa - Bb.bb - C3.c3 - Cc.cc - 1 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/myocamlbuild.ml: -------------------------------------------------------------------------------- 1 | open Ocamlbuild_plugin;; 2 | dispatch begin function 3 | | After_rules -> 4 | use_lib "main" "bbcc"; 5 | dep ["ocaml"; "link"; "byte"; "my_cool_plugin"] ["cool_plugin.cmo"]; 6 | | _ -> () 7 | end 8 | -------------------------------------------------------------------------------- /ocamlbuild/test/test7/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | cd `dirname $0` 3 | set -e 4 | set -x 5 | CMDOPTS="" # -- command args 6 | BUILD="../../_build/ocamlbuild.native bbcc.cma main.byte bbcc.cmxa main.native -no-skip -classic-display $@" 7 | BUILD1="$BUILD $CMDARGS" 8 | BUILD2="$BUILD -verbose 0 -nothing-should-be-rebuilt $CMDARGS" 9 | rm -rf _build 10 | cp bb1.ml bb.ml 11 | $BUILD1 12 | $BUILD2 13 | cp bb2.ml bb.ml 14 | $BUILD1 -verbose 0 15 | $BUILD2 16 | cp bb3.ml bb.ml 17 | $BUILD1 -verbose 0 18 | $BUILD2 19 | -------------------------------------------------------------------------------- /ocamlbuild/test/test8/a.ml: -------------------------------------------------------------------------------- 1 | print_endline Myconfig.version;; 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test8/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | cd `dirname $0` 3 | set -e 4 | set -x 5 | CMDOPTS="" # -- command args 6 | BUILD="../../_build/ocamlbuild.native a.byte a.native a a.opt bin/a bin/a.opt -no-skip -classic-display $@" 7 | BUILD1="$BUILD $CMDOPTS" 8 | BUILD2="$BUILD -verbose 0 -nothing-should-be-rebuilt $CMDOPTS" 9 | rm -rf _build 10 | $BUILD1 11 | $BUILD2 12 | -------------------------------------------------------------------------------- /ocamlbuild/test/test9/dbgl: -------------------------------------------------------------------------------- 1 | #load "unix.cma";; 2 | #load "str.cma";; 3 | #load "discard_printf.cmo";; 4 | #load "debug.cmo";; 5 | #load "bool.cmo";; 6 | #load "glob_ast.cmo";; 7 | #load "glob_lexer.cmo";; 8 | #load "my_unix.cmo";; 9 | #use "glob.ml";; 10 | #install_printer print_is;; 11 | -------------------------------------------------------------------------------- /ocamlbuild/test/test9/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | set -e 3 | set -x 4 | cd `dirname $0`/../.. 5 | ./_build/ocamlbuild.native -quiet -build-dir _buildtest -no-links test/test9/testglob.native $@ 6 | ./_buildtest/test/test9/testglob.native 7 | -------------------------------------------------------------------------------- /ocamlbuild/test/test_virtual/foo.itarget: -------------------------------------------------------------------------------- 1 | foo 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test_virtual/foo1: -------------------------------------------------------------------------------- 1 | foo1 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test_virtual/foo2: -------------------------------------------------------------------------------- 1 | foo2 2 | -------------------------------------------------------------------------------- /ocamlbuild/test/test_virtual/myocamlbuild.ml: -------------------------------------------------------------------------------- 1 | open Ocamlbuild_plugin;; 2 | dispatch begin function 3 | | After_rules -> 4 | rule "copy foo" 5 | ~prod:"bar" 6 | ~dep:"foo.otarget" 7 | begin fun _env _build -> 8 | cp "foo" "bar" 9 | end 10 | | _ -> () 11 | end 12 | -------------------------------------------------------------------------------- /ocamlbuild/test/test_virtual/test.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | cd `dirname $0` 3 | set -e 4 | set -x 5 | CMDOPTS="" # -- command args 6 | BUILD="../../_build/ocamlbuild.native bar -no-skip -classic-display $@" 7 | BUILD1="$BUILD $CMDOPTS" 8 | BUILD2="$BUILD -verbose 0 -nothing-should-be-rebuilt $CMDOPTS" 9 | rm -rf _build 10 | cp foo1 foo 11 | $BUILD1 12 | $BUILD2 13 | cp foo2 foo 14 | $BUILD1 -verbose 0 15 | $BUILD2 16 | rm foo 17 | -------------------------------------------------------------------------------- /ocamldoc/.cvsignore: -------------------------------------------------------------------------------- 1 | ocamldoc 2 | ocamldoc.opt 3 | odoc_crc.ml 4 | odoc_lexer.ml 5 | odoc_ocamlhtml.ml 6 | odoc_parser.ml 7 | odoc_parser.mli 8 | odoc_see_lexer.ml 9 | odoc_text_lexer.ml 10 | odoc_text_parser.ml 11 | odoc_text_parser.mli 12 | stdlib_man 13 | *.output 14 | test_stdlib 15 | test_latex 16 | test 17 | *.a 18 | -------------------------------------------------------------------------------- /ocamldoc/Changes.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/Changes.txt -------------------------------------------------------------------------------- /ocamldoc/odoc_ast.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_ast.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_class.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_class.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_env.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_env.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_html.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_html.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_latex.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_latex.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_lexer.mll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_lexer.mll -------------------------------------------------------------------------------- /ocamldoc/odoc_merge.mli: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_merge.mli -------------------------------------------------------------------------------- /ocamldoc/odoc_messages.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_messages.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_misc.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_misc.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_print.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_print.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_scan.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_scan.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_sig.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_sig.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_texi.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_texi.ml -------------------------------------------------------------------------------- /ocamldoc/odoc_text_lexer.mll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/ocamldoc/odoc_text_lexer.mll -------------------------------------------------------------------------------- /ocamldoc/runocamldoc: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # $Id$ 3 | 4 | case "$1" in 5 | true) shift 6 | exec ../boot/ocamlrun -I ../otherlibs/unix -I ../otherlibs/str \ 7 | ./ocamldoc "$@" 8 | ;; 9 | *) shift 10 | exec ./ocamldoc "$@" 11 | ;; 12 | esac 13 | -------------------------------------------------------------------------------- /otherlibs/bigarray/.cvsignore: -------------------------------------------------------------------------------- 1 | *.o 2 | *.x 3 | so_locations 4 | *.so 5 | *.a 6 | -------------------------------------------------------------------------------- /otherlibs/bigarray/libbigarray.clib: -------------------------------------------------------------------------------- 1 | bigarray_stubs.o mmap_unix.o 2 | -------------------------------------------------------------------------------- /otherlibs/bigarray/libbigarraywin32.clib: -------------------------------------------------------------------------------- 1 | bigarray_stubs.o mmap_win32.o 2 | -------------------------------------------------------------------------------- /otherlibs/dbm/.cvsignore: -------------------------------------------------------------------------------- 1 | so_locations 2 | *.so 3 | *.a 4 | -------------------------------------------------------------------------------- /otherlibs/dbm/.depend: -------------------------------------------------------------------------------- 1 | dbm.cmi: 2 | dbm.cmo: dbm.cmi 3 | dbm.cmx: dbm.cmi 4 | -------------------------------------------------------------------------------- /otherlibs/dbm/libmldbm.clib: -------------------------------------------------------------------------------- 1 | cldbm.o 2 | -------------------------------------------------------------------------------- /otherlibs/dynlink/.cvsignore: -------------------------------------------------------------------------------- 1 | extract_crc 2 | *.a 3 | -------------------------------------------------------------------------------- /otherlibs/dynlink/dynlinkaux.mlpack: -------------------------------------------------------------------------------- 1 | Misc Config Clflags Tbl Consistbl 2 | Terminfo Warnings Asttypes Linenum Location Longident 3 | Ident Path Primitive Types Btype Subst Predef 4 | Datarepr Env Lambda Instruct Cmo_format Opcodes 5 | Runtimedef Bytesections Dll Meta Symtable 6 | -------------------------------------------------------------------------------- /otherlibs/graph/.cvsignore: -------------------------------------------------------------------------------- 1 | so_locations 2 | *.so 3 | *.a 4 | -------------------------------------------------------------------------------- /otherlibs/graph/graphics.mllib: -------------------------------------------------------------------------------- 1 | Graphics GraphicsX11 2 | -------------------------------------------------------------------------------- /otherlibs/graph/libgraphics.clib: -------------------------------------------------------------------------------- 1 | open.o draw.o fill.o color.o text.o 2 | image.o make_img.o dump_img.o point_col.o sound.o events.o 3 | subwindow.o 4 | -------------------------------------------------------------------------------- /otherlibs/labltk/.cvsignore: -------------------------------------------------------------------------------- 1 | labltklink 2 | labltkopt 3 | Makefile.config 4 | config.status 5 | -------------------------------------------------------------------------------- /otherlibs/labltk/browser/.cvsignore: -------------------------------------------------------------------------------- 1 | ocamlbrowser 2 | dummy.mli 3 | -------------------------------------------------------------------------------- /otherlibs/labltk/browser/Makefile: -------------------------------------------------------------------------------- 1 | # $Id$ 2 | 3 | OTHERSLIB=-I $(OTHERS)/unix -I $(OTHERS)/str 4 | 5 | include Makefile.shared 6 | 7 | dummy.mli: 8 | cp dummyUnix.mli dummy.mli 9 | -------------------------------------------------------------------------------- /otherlibs/labltk/browser/Makefile.nt: -------------------------------------------------------------------------------- 1 | # $Id$ 2 | 3 | OTHERSLIB=-I $(OTHERS)/win32unix -I $(OTHERS)/str -I $(OTHERS)/systhreads 4 | 5 | CCFLAGS=-I../../../byterun $(TK_DEFS) 6 | 7 | include ../support/Makefile.common 8 | 9 | ifeq ($(CCOMPTYPE),cc) 10 | WINDOWS_APP=-ccopt "-link -Wl,--subsystem,windows" 11 | else 12 | WINDOWS_APP=-ccopt "-link /subsystem:windows" 13 | endif 14 | 15 | XTRAOBJ=winmain.$(O) 16 | XTRALIBS=threads.cma -custom $(WINDOWS_APP) 17 | 18 | include Makefile.shared 19 | 20 | dummy.mli: 21 | cp dummyWin.mli dummy.mli 22 | -------------------------------------------------------------------------------- /otherlibs/labltk/browser/jglib.mllib: -------------------------------------------------------------------------------- 1 | Jg_tk 2 | Jg_config 3 | Jg_bind 4 | Jg_completion 5 | Jg_box 6 | Jg_button 7 | Jg_toplevel 8 | Jg_text 9 | Jg_message 10 | Jg_menu 11 | Jg_entry 12 | Jg_multibox 13 | Jg_memo 14 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/builtin_GetBitmap.ml: -------------------------------------------------------------------------------- 1 | (* Tk_GetBitmap emulation *) 2 | 3 | ##ifdef CAMLTK 4 | 5 | (* type *) 6 | type bitmap = 7 | | BitmapFile of string (* path of file *) 8 | | Predefined of string (* bitmap name *) 9 | ;; 10 | (* /type *) 11 | 12 | ##else 13 | 14 | (* type *) 15 | type bitmap = [ 16 | | `File of string (* path of file *) 17 | | `Predefined of string (* bitmap name *) 18 | ] 19 | ;; 20 | (* /type *) 21 | 22 | ##endif 23 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/builtin_bindtags.ml: -------------------------------------------------------------------------------- 1 | ##ifdef CAMLTK 2 | 3 | (* type *) 4 | type bindings = 5 | | TagBindings of string (* tk option: *) 6 | | WidgetBindings of widget (* tk option: *) 7 | ;; 8 | (* /type *) 9 | 10 | ##else 11 | 12 | (* type *) 13 | type bindings = [ 14 | | `Tag of string (* tk option: *) 15 | | `Widget of any widget (* tk option: *) 16 | ] 17 | ;; 18 | (* /type *) 19 | 20 | ##endif 21 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/builtin_font.ml: -------------------------------------------------------------------------------- 1 | (* type *) 2 | type font = string 3 | (* /type *) 4 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/builtin_grab.ml: -------------------------------------------------------------------------------- 1 | (* type *) 2 | type grabGlobal = bool 3 | (* /type *) 4 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/builtin_palette.ml: -------------------------------------------------------------------------------- 1 | ##ifdef CAMLTK 2 | 3 | (* type *) 4 | type paletteType = 5 | | GrayShades of int 6 | | RGBShades of int * int * int 7 | ;; 8 | (* /type *) 9 | 10 | ##else 11 | 12 | (* type *) 13 | type paletteType = [ 14 | | `Gray of int 15 | | `Rgb of int * int * int 16 | ] 17 | ;; 18 | (* /type *) 19 | 20 | ##endif 21 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/builtina_empty.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/otherlibs/labltk/builtin/builtina_empty.ml -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/builtini_font.ml: -------------------------------------------------------------------------------- 1 | let cCAMLtoTKfont (s : font) = TkToken s 2 | let cTKtoCAMLfont (s : font) = s 3 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/builtini_grab.ml: -------------------------------------------------------------------------------- 1 | let cCAMLtoTKgrabGlobal x = 2 | if x then TkToken "-global" else TkTokenList [] 3 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/canvas_bind.mli: -------------------------------------------------------------------------------- 1 | ##ifdef CAMLTK 2 | 3 | val bind : widget -> tagOrId -> 4 | (modifier list * xEvent) list -> bindAction -> unit 5 | 6 | ##else 7 | 8 | val bind : 9 | events: event list -> 10 | ?extend: bool -> 11 | ?breakable: bool -> 12 | ?fields: eventField list -> 13 | ?action: (eventInfo -> unit) -> 14 | canvas widget -> tagOrId -> unit 15 | 16 | ##endif 17 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/image.mli: -------------------------------------------------------------------------------- 1 | ##ifdef CAMLTK 2 | 3 | val names : unit -> options list 4 | 5 | ##else 6 | 7 | val names : unit -> image list 8 | 9 | ##endif 10 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/selection_handle_set.mli: -------------------------------------------------------------------------------- 1 | ##ifdef CAMLTK 2 | 3 | val handle_set : icccm list -> widget -> (int -> int -> unit) -> unit 4 | (** tk invocation: selection handle *) 5 | 6 | ##else 7 | 8 | val handle_set : 9 | command: (pos:int -> len:int -> string) -> 10 | ?format: string -> ?selection:string -> ?typ: string -> 'a widget -> unit 11 | (** tk invocation: selection handle *) 12 | 13 | ##endif 14 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/selection_own_set.mli: -------------------------------------------------------------------------------- 1 | ##ifdef CAMLTK 2 | 3 | val own_set : icccm list -> widget -> unit 4 | (** tk invocation: selection own *) 5 | 6 | ##else 7 | 8 | val own_set : 9 | ?command:(unit->unit) -> ?selection:string -> 'a widget -> unit 10 | (** tk invocation: selection own *) 11 | 12 | ##endif 13 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/text_tag_bind.mli: -------------------------------------------------------------------------------- 1 | ##ifdef CAMLTK 2 | 3 | val tag_bind: 4 | widget -> textTag -> (modifier list * xEvent) list -> bindAction -> unit 5 | 6 | ##else 7 | 8 | val tag_bind : 9 | tag: string -> events: event list -> 10 | ?extend: bool -> ?breakable: bool -> ?fields: eventField list -> 11 | ?action: (eventInfo -> unit) -> text widget -> unit 12 | 13 | ##endif 14 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/winfo_contained.ml: -------------------------------------------------------------------------------- 1 | ##ifdef CAMLTK 2 | 3 | let contained x y w = 4 | w = containing x y 5 | ;; 6 | 7 | ##else 8 | 9 | let contained ~x ~y w = 10 | forget_type w = containing ~x ~y () 11 | ;; 12 | 13 | ##endif 14 | -------------------------------------------------------------------------------- /otherlibs/labltk/builtin/winfo_contained.mli: -------------------------------------------------------------------------------- 1 | ##ifdef CAMLTK 2 | 3 | val contained : int -> int -> widget -> bool 4 | (** [contained x y w] returns true if (x,y) is in w *) 5 | 6 | ##else 7 | 8 | val contained : x:int -> y:int -> 'a widget -> bool 9 | (** [contained x y w] returns true if (x,y) is in w *) 10 | 11 | ##endif 12 | -------------------------------------------------------------------------------- /otherlibs/labltk/camltk/.cvsignore: -------------------------------------------------------------------------------- 1 | *.ml *.mli labltktop labltk 2 | modules 3 | .depend 4 | -------------------------------------------------------------------------------- /otherlibs/labltk/camltk/Makefile.gen.nt: -------------------------------------------------------------------------------- 1 | include Makefile.gen 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/camltk/Makefile.nt: -------------------------------------------------------------------------------- 1 | include Makefile 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/camltk/native.itarget: -------------------------------------------------------------------------------- 1 | cPlace.cmx cResource.cmx cWm.cmx cImagephoto.cmx cCanvas.cmx cButton.cmx 2 | cText.cmx cLabel.cmx cScrollbar.cmx cImage.cmx cEncoding.cmx cPixmap.cmx 3 | cPalette.cmx cFont.cmx cMessage.cmx cMenu.cmx cEntry.cmx cListbox.cmx 4 | cFocus.cmx cMenubutton.cmx cPack.cmx cOption.cmx cToplevel.cmx cFrame.cmx 5 | cDialog.cmx cImagebitmap.cmx cClipboard.cmx cRadiobutton.cmx cTkwait.cmx 6 | cGrab.cmx cSelection.cmx cScale.cmx cOptionmenu.cmx cWinfo.cmx cGrid.cmx 7 | cCheckbutton.cmx cBell.cmx cTkvars.cmx 8 | -------------------------------------------------------------------------------- /otherlibs/labltk/compiler/.cvsignore: -------------------------------------------------------------------------------- 1 | lexer.ml 2 | parser.output 3 | parser.ml 4 | parser.mli 5 | tkcompiler 6 | pp 7 | copyright.ml 8 | pplex.ml 9 | ppyac.ml 10 | ppyac.output 11 | ppyac.mli 12 | -------------------------------------------------------------------------------- /otherlibs/labltk/compiler/Makefile.nt: -------------------------------------------------------------------------------- 1 | include Makefile 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/examples_camltk/.cvsignore: -------------------------------------------------------------------------------- 1 | addition 2 | eyes 3 | fileinput 4 | fileopen 5 | helloworld 6 | tetris 7 | winskel 8 | mytext 9 | -------------------------------------------------------------------------------- /otherlibs/labltk/examples_camltk/images/CamlBook.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/otherlibs/labltk/examples_camltk/images/CamlBook.gif -------------------------------------------------------------------------------- /otherlibs/labltk/examples_camltk/images/Lambda2.back.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/otherlibs/labltk/examples_camltk/images/Lambda2.back.gif -------------------------------------------------------------------------------- /otherlibs/labltk/examples_camltk/images/dojoji.back.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/otherlibs/labltk/examples_camltk/images/dojoji.back.gif -------------------------------------------------------------------------------- /otherlibs/labltk/examples_camltk/jptest.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/otherlibs/labltk/examples_camltk/jptest.ml -------------------------------------------------------------------------------- /otherlibs/labltk/examples_labltk/.cvsignore: -------------------------------------------------------------------------------- 1 | calc 2 | clock 3 | demo 4 | eyes 5 | hello 6 | tetris 7 | lang 8 | taquin 9 | -------------------------------------------------------------------------------- /otherlibs/labltk/examples_labltk/Lambda2.back.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/otherlibs/labltk/examples_labltk/Lambda2.back.gif -------------------------------------------------------------------------------- /otherlibs/labltk/examples_labltk/hello.tcl: -------------------------------------------------------------------------------- 1 | #!/usr/bin/wish 2 | 3 | button .hello -text "Hello, TclTk!" 4 | 5 | pack .hello 6 | -------------------------------------------------------------------------------- /otherlibs/labltk/examples_labltk/taquin.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/otherlibs/labltk/examples_labltk/taquin.ml -------------------------------------------------------------------------------- /otherlibs/labltk/frx/.cvsignore: -------------------------------------------------------------------------------- 1 | *.a 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/frx/Makefile.nt: -------------------------------------------------------------------------------- 1 | include Makefile 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/frx/README: -------------------------------------------------------------------------------- 1 | This is Francois Rouaix's widget set library, Frx. 2 | It uses CamlTk API. -------------------------------------------------------------------------------- /otherlibs/labltk/frx/frxlib.mllib: -------------------------------------------------------------------------------- 1 | Frx_misc Frx_widget Frx_font Frx_entry Frx_text 2 | Frx_listbox Frx_req Frx_fillbox Frx_focus 3 | Frx_dialog Frx_mem Frx_rpc Frx_synth Frx_selection 4 | Frx_after Frx_fit Frx_ctext Frx_color 5 | -------------------------------------------------------------------------------- /otherlibs/labltk/jpf/.cvsignore: -------------------------------------------------------------------------------- 1 | *.a 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/jpf/Makefile.nt: -------------------------------------------------------------------------------- 1 | include Makefile 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/jpf/README: -------------------------------------------------------------------------------- 1 | This is Jun Furuse's widget set library, Jpf. 2 | It uses LablTk API. 3 | -------------------------------------------------------------------------------- /otherlibs/labltk/jpf/jpflib.mllib: -------------------------------------------------------------------------------- 1 | Fileselect Balloon Shell Jpf_font 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/labl.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/otherlibs/labltk/labl.gif -------------------------------------------------------------------------------- /otherlibs/labltk/labltk/.cvsignore: -------------------------------------------------------------------------------- 1 | *.ml *.mli labltktop labltk 2 | modules 3 | .depend 4 | -------------------------------------------------------------------------------- /otherlibs/labltk/labltk/Makefile.gen.nt: -------------------------------------------------------------------------------- 1 | include Makefile.gen 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/labltk/Makefile.nt: -------------------------------------------------------------------------------- 1 | include Makefile 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/labltk/byte.itarget: -------------------------------------------------------------------------------- 1 | place.cmo wm.cmo imagephoto.cmo canvas.cmo button.cmo text.cmo label.cmo 2 | scrollbar.cmo image.cmo encoding.cmo pixmap.cmo palette.cmo font.cmo 3 | message.cmo menu.cmo entry.cmo listbox.cmo focus.cmo menubutton.cmo pack.cmo 4 | option.cmo toplevel.cmo frame.cmo dialog.cmo imagebitmap.cmo clipboard.cmo 5 | radiobutton.cmo tkwait.cmo grab.cmo selection.cmo scale.cmo optionmenu.cmo 6 | winfo.cmo grid.cmo checkbutton.cmo bell.cmo tkvars.cmo 7 | 8 | tk.cmo labltk.cmo 9 | -------------------------------------------------------------------------------- /otherlibs/labltk/labltk/native.itarget: -------------------------------------------------------------------------------- 1 | place.cmx wm.cmx imagephoto.cmx canvas.cmx button.cmx text.cmx label.cmx 2 | scrollbar.cmx image.cmx encoding.cmx pixmap.cmx palette.cmx font.cmx 3 | message.cmx menu.cmx entry.cmx listbox.cmx focus.cmx menubutton.cmx pack.cmx 4 | option.cmx toplevel.cmx frame.cmx dialog.cmx imagebitmap.cmx clipboard.cmx 5 | radiobutton.cmx tkwait.cmx grab.cmx selection.cmx scale.cmx optionmenu.cmx 6 | winfo.cmx grid.cmx checkbutton.cmx bell.cmx tkvars.cmx 7 | -------------------------------------------------------------------------------- /otherlibs/labltk/lib/.cvsignore: -------------------------------------------------------------------------------- 1 | labltktop labltk mltktop mltk 2 | .depend 3 | *.ml 4 | *.mli 5 | modules 6 | labltk.cma 7 | labltk.cmxa 8 | *.a 9 | -------------------------------------------------------------------------------- /otherlibs/labltk/lib/Makefile.nt: -------------------------------------------------------------------------------- 1 | include Makefile -------------------------------------------------------------------------------- /otherlibs/labltk/lib/labltk.bat: -------------------------------------------------------------------------------- 1 | @ocaml -I +labltk labltk.cma %1 %2 %3 %4 %5 %6 %7 %8 %9 -------------------------------------------------------------------------------- /otherlibs/labltk/support/.cvsignore: -------------------------------------------------------------------------------- 1 | *.so 2 | *.a 3 | -------------------------------------------------------------------------------- /otherlibs/labltk/support/Makefile.nt: -------------------------------------------------------------------------------- 1 | include Makefile 2 | -------------------------------------------------------------------------------- /otherlibs/labltk/support/byte.itarget: -------------------------------------------------------------------------------- 1 | support.cmo rawwidget.cmo widget.cmo protocol.cmo 2 | textvariable.cmo timer.cmo fileevent.cmo camltkwrap.cmo 3 | tkthread.cmo 4 | -------------------------------------------------------------------------------- /otherlibs/labltk/support/liblabltk.clib: -------------------------------------------------------------------------------- 1 | cltkCaml.o cltkUtf.o cltkEval.o cltkEvent.o cltkFile.o cltkMain.o 2 | cltkMisc.o cltkTimer.o cltkVar.o cltkWait.o cltkImg.o 3 | -------------------------------------------------------------------------------- /otherlibs/labltk/support/native.itarget: -------------------------------------------------------------------------------- 1 | support.cmx rawwidget.cmx widget.cmx protocol.cmx 2 | textvariable.cmx timer.cmx fileevent.cmx camltkwrap.cmx 3 | tkthread.cmx 4 | -------------------------------------------------------------------------------- /otherlibs/num/.cvsignore: -------------------------------------------------------------------------------- 1 | libnums.x 2 | *.c.x 3 | so_locations 4 | *.so 5 | *.a 6 | -------------------------------------------------------------------------------- /otherlibs/num/bignum/.cvsignore: -------------------------------------------------------------------------------- 1 | libbignum.x 2 | -------------------------------------------------------------------------------- /otherlibs/num/libnums.clib: -------------------------------------------------------------------------------- 1 | bng.o nat_stubs.o 2 | -------------------------------------------------------------------------------- /otherlibs/num/nat.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/otherlibs/num/nat.ml -------------------------------------------------------------------------------- /otherlibs/num/nums.mllib: -------------------------------------------------------------------------------- 1 | Int_misc Nat Big_int Arith_flags Ratio Num Arith_status 2 | -------------------------------------------------------------------------------- /otherlibs/str/.cvsignore: -------------------------------------------------------------------------------- 1 | libstr.x 2 | *.c.x 3 | so_locations 4 | *.so 5 | *.a 6 | -------------------------------------------------------------------------------- /otherlibs/str/.depend: -------------------------------------------------------------------------------- 1 | strstubs.o: strstubs.c ../../byterun/mlvalues.h \ 2 | ../../byterun/compatibility.h ../../byterun/config.h \ 3 | ../../byterun/../config/m.h ../../byterun/../config/s.h \ 4 | ../../byterun/misc.h ../../byterun/alloc.h ../../byterun/mlvalues.h \ 5 | ../../byterun/memory.h ../../byterun/gc.h ../../byterun/major_gc.h \ 6 | ../../byterun/freelist.h ../../byterun/minor_gc.h ../../byterun/fail.h 7 | str.cmi: 8 | str.cmo: str.cmi 9 | str.cmx: str.cmi 10 | -------------------------------------------------------------------------------- /otherlibs/str/libstr.clib: -------------------------------------------------------------------------------- 1 | strstubs.o 2 | -------------------------------------------------------------------------------- /otherlibs/systhreads/.cvsignore: -------------------------------------------------------------------------------- 1 | *.x 2 | thread.ml 3 | so_locations 4 | *.so 5 | *.a 6 | -------------------------------------------------------------------------------- /otherlibs/systhreads/libthreads.clib: -------------------------------------------------------------------------------- 1 | st_stubs_b.o 2 | -------------------------------------------------------------------------------- /otherlibs/systhreads/threads.mllib: -------------------------------------------------------------------------------- 1 | Thread Mutex Condition Event ThreadUnix 2 | -------------------------------------------------------------------------------- /otherlibs/threads/.cvsignore: -------------------------------------------------------------------------------- 1 | marshal.mli 2 | pervasives.mli 3 | unix.mli 4 | *.so 5 | *.a 6 | -------------------------------------------------------------------------------- /otherlibs/threads/libvmthreads.clib: -------------------------------------------------------------------------------- 1 | scheduler.o 2 | -------------------------------------------------------------------------------- /otherlibs/threads/threads.mllib: -------------------------------------------------------------------------------- 1 | Thread Mutex Condition Event ThreadUnix 2 | -------------------------------------------------------------------------------- /otherlibs/threads/unix.mllib: -------------------------------------------------------------------------------- 1 | Unix UnixLabels 2 | -------------------------------------------------------------------------------- /otherlibs/unix/.cvsignore: -------------------------------------------------------------------------------- 1 | so_locations 2 | *.so 3 | *.a 4 | -------------------------------------------------------------------------------- /otherlibs/unix/unix.mllib: -------------------------------------------------------------------------------- 1 | Unix UnixLabels 2 | -------------------------------------------------------------------------------- /otherlibs/win32graph/.cvsignore: -------------------------------------------------------------------------------- 1 | graphics.ml 2 | graphics.mli 3 | -------------------------------------------------------------------------------- /otherlibs/win32graph/libgraphics.clib: -------------------------------------------------------------------------------- 1 | open.o draw.o events.o dib.o 2 | -------------------------------------------------------------------------------- /otherlibs/win32unix/.cvsignore: -------------------------------------------------------------------------------- 1 | unixLabels.ml* 2 | unix.mli 3 | unix.lib 4 | access.c 5 | addrofstr.c 6 | chdir.c 7 | chmod.c 8 | cst2constr.c 9 | cstringv.c 10 | envir.c 11 | execv.c 12 | execve.c 13 | execvp.c 14 | exit.c 15 | getcwd.c 16 | gethost.c 17 | gethostname.c 18 | getproto.c 19 | getserv.c 20 | gmtime.c 21 | putenv.c 22 | rmdir.c 23 | socketaddr.c 24 | strofaddr.c 25 | time.c 26 | unlink.c 27 | utimes.c 28 | -------------------------------------------------------------------------------- /otherlibs/win32unix/.depend: -------------------------------------------------------------------------------- 1 | unix.cmo: unix.cmi 2 | unix.cmx: unix.cmi 3 | unixLabels.cmo: unix.cmi unixLabels.cmi 4 | unixLabels.cmx: unix.cmx unixLabels.cmi 5 | unixLabels.cmi: unix.cmi 6 | -------------------------------------------------------------------------------- /parsing/.cvsignore: -------------------------------------------------------------------------------- 1 | parser.ml 2 | parser.mli 3 | lexer.ml 4 | lexer_tmp.mll 5 | lexer_tmp.ml 6 | linenum.ml 7 | parser.output 8 | parser.automaton 9 | parser.conflicts 10 | -------------------------------------------------------------------------------- /stdlib/.cvsignore: -------------------------------------------------------------------------------- 1 | camlheader 2 | camlheader_ur 3 | labelled-* 4 | caml 5 | *.annot 6 | sys.ml 7 | *.a 8 | -------------------------------------------------------------------------------- /stdlib/buffer.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/stdlib/buffer.ml -------------------------------------------------------------------------------- /stdlib/queue.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/stdlib/queue.ml -------------------------------------------------------------------------------- /stdlib/sharpbang: -------------------------------------------------------------------------------- 1 | #! -------------------------------------------------------------------------------- /testlabl/.cvsignore: -------------------------------------------------------------------------------- 1 | *.out *.out2 -------------------------------------------------------------------------------- /testlabl/dirs_multimatch: -------------------------------------------------------------------------------- 1 | parsing typing bytecomp driver toplevel -------------------------------------------------------------------------------- /testlabl/dirs_poly: -------------------------------------------------------------------------------- 1 | bytecomp byterun driver parsing stdlib tools toplevel typing utils otherlibs/labltk/browser/searchpos.ml 2 | -------------------------------------------------------------------------------- /testlabl/printers.ml: -------------------------------------------------------------------------------- 1 | (* $Id$ *) 2 | 3 | open Types 4 | 5 | let ignore_abbrevs ppf ab = 6 | let s = match ab with 7 | Mnil -> "Mnil" 8 | | Mlink _ -> "Mlink _" 9 | | Mcons _ -> "Mcons _" 10 | in 11 | Format.pp_print_string ppf s 12 | -------------------------------------------------------------------------------- /testsuite/.svnignore: -------------------------------------------------------------------------------- 1 | # svn propset -R svn:ignore -F .svnignore . 2 | # find . -name .svnignore -print | while read f; do svn propset svn:ignore -F $f `dirname $f`; done 3 | _log 4 | *.so 5 | *.a 6 | *.result 7 | *.byte 8 | *.native 9 | program 10 | -------------------------------------------------------------------------------- /testsuite/interactive/lib-gc/Makefile: -------------------------------------------------------------------------------- 1 | default: 2 | @$(OCAMLC) -o program.byte alloc.ml 3 | @./program.byte 4 | @$(OCAMLOPT) -o program.native alloc.ml 5 | @./program.native 6 | 7 | clean: defaultclean 8 | @rm -fr program.* 9 | 10 | include ../../makefiles/Makefile.common 11 | -------------------------------------------------------------------------------- /testsuite/interactive/lib-graph-2/Makefile: -------------------------------------------------------------------------------- 1 | #MODULES= 2 | MAIN_MODULE=graph_test 3 | #ADD_COMPFLAGS= 4 | LIBRARIES=graphics 5 | 6 | include ../../makefiles/Makefile.one 7 | include ../../makefiles/Makefile.common 8 | -------------------------------------------------------------------------------- /testsuite/interactive/lib-graph-2/graph_test.reference: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/interactive/lib-graph-2/graph_test.reference -------------------------------------------------------------------------------- /testsuite/interactive/lib-graph-3/Makefile: -------------------------------------------------------------------------------- 1 | #MODULES= 2 | MAIN_MODULE=sorts 3 | ADD_COMPFLAGS=-thread 4 | LIBRARIES=unix threads graphics 5 | 6 | include ../../makefiles/Makefile.one 7 | include ../../makefiles/Makefile.common 8 | -------------------------------------------------------------------------------- /testsuite/interactive/lib-graph-3/sorts.reference: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/interactive/lib-graph-3/sorts.reference -------------------------------------------------------------------------------- /testsuite/interactive/lib-graph/Makefile: -------------------------------------------------------------------------------- 1 | #MODULES= 2 | MAIN_MODULE=graph_example 3 | #ADD_COMPFLAGS= 4 | LIBRARIES=graphics 5 | 6 | include ../../makefiles/Makefile.one 7 | include ../../makefiles/Makefile.common 8 | -------------------------------------------------------------------------------- /testsuite/interactive/lib-graph/graph_example.reference: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/interactive/lib-graph/graph_example.reference -------------------------------------------------------------------------------- /testsuite/interactive/lib-signals/Makefile: -------------------------------------------------------------------------------- 1 | default: 2 | @$(OCAMLC) -o program.byte signals.ml 3 | @./program.byte 4 | @$(OCAMLOPT) -o program.native signals.ml 5 | @./program.native 6 | 7 | clean: defaultclean 8 | @rm -fr program.* 9 | 10 | include ../../makefiles/Makefile.common 11 | -------------------------------------------------------------------------------- /testsuite/lib/Makefile: -------------------------------------------------------------------------------- 1 | # $Id$ 2 | 3 | compile: testing.cmi testing.cmo testing.cmx 4 | 5 | clean: defaultclean 6 | 7 | include ../makefiles/Makefile.common 8 | -------------------------------------------------------------------------------- /testsuite/tests/asmcomp/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . < print_string "a"; print_newline(); 0 12 | | Error "b" as exn -> print_string "b"; print_newline(); raise exn 13 | | Error "c" -> raise (Error "c") 14 | 15 | let _ = 16 | Printexc.record_backtrace true; 17 | ignore (g Sys.argv.(1)) 18 | -------------------------------------------------------------------------------- /testsuite/tests/basic-float/Makefile: -------------------------------------------------------------------------------- 1 | MODULES=float_record 2 | MAIN_MODULE=tfloat_record 3 | 4 | include ../../makefiles/Makefile.one 5 | include ../../makefiles/Makefile.common 6 | -------------------------------------------------------------------------------- /testsuite/tests/basic-float/float_record.ml: -------------------------------------------------------------------------------- 1 | type t = float;; 2 | 3 | let make f = f;; 4 | 5 | let from t = t;; 6 | 7 | type s = {f : t};; 8 | -------------------------------------------------------------------------------- /testsuite/tests/basic-float/float_record.mli: -------------------------------------------------------------------------------- 1 | type t = private float;; 2 | 3 | val make : float -> t;; 4 | val from : t -> float;; 5 | 6 | type s = {f : t};; 7 | -------------------------------------------------------------------------------- /testsuite/tests/basic-float/tfloat_record.ml: -------------------------------------------------------------------------------- 1 | let s = { Float_record.f = Float_record.make 1.0 };; 2 | 3 | print_float (Float_record.from s.Float_record.f);; 4 | print_newline ();; 5 | 6 | -------------------------------------------------------------------------------- /testsuite/tests/basic-float/tfloat_record.reference: -------------------------------------------------------------------------------- 1 | 1. 2 | -------------------------------------------------------------------------------- /testsuite/tests/basic-io-2/Makefile: -------------------------------------------------------------------------------- 1 | #MODULES= 2 | MAIN_MODULE=io 3 | EXEC_ARGS=io.ml 4 | 5 | include ../../makefiles/Makefile.one 6 | include ../../makefiles/Makefile.common 7 | -------------------------------------------------------------------------------- /testsuite/tests/basic-io-2/io.reference: -------------------------------------------------------------------------------- 1 | 16-byte chunks 2 | passed 3 | 256-byte chunks 4 | passed 5 | 4096-byte chunks 6 | passed 7 | 65536-byte chunks 8 | passed 9 | 19-byte chunks 10 | passed 11 | 263-byte chunks 12 | passed 13 | 4011-byte chunks 14 | passed 15 | 0...8192 byte chunks 16 | passed 17 | line per line, short lines 18 | passed 19 | line per line, short and long lines 20 | passed 21 | backwards, 4096-byte chunks 22 | passed 23 | backwards, 64-byte chunks 24 | passed 25 | -------------------------------------------------------------------------------- /testsuite/tests/basic-io/Makefile: -------------------------------------------------------------------------------- 1 | #MODULES= 2 | MAIN_MODULE=wc 3 | EXEC_ARGS=wc.ml 4 | 5 | include ../../makefiles/Makefile.one 6 | include ../../makefiles/Makefile.common 7 | -------------------------------------------------------------------------------- /testsuite/tests/basic-io/wc.reference: -------------------------------------------------------------------------------- 1 | 1198 characters, 178 words, 54 lines 2 | -------------------------------------------------------------------------------- /testsuite/tests/basic-manyargs/Makefile: -------------------------------------------------------------------------------- 1 | #MODULES= 2 | MAIN_MODULE=manyargs 3 | C_FILES=manyargsprim 4 | 5 | include ../../makefiles/Makefile.one 6 | include ../../makefiles/Makefile.common 7 | -------------------------------------------------------------------------------- /testsuite/tests/basic-more/Makefile: -------------------------------------------------------------------------------- 1 | MODULES=testing 2 | 3 | include ../../makefiles/Makefile.several 4 | include ../../makefiles/Makefile.common 5 | -------------------------------------------------------------------------------- /testsuite/tests/basic-more/bounds.reference: -------------------------------------------------------------------------------- 1 | 0: doesn't fail 2 | 1: doesn't fail 3 | 2: doesn't fail 4 | 3: fails 5 | 4: fails 6 | -1: fails 7 | Trail: -1 4 3 2 1 0 8 | 9 | All tests succeeded. 10 | -------------------------------------------------------------------------------- /testsuite/tests/basic-more/morematch.reference: -------------------------------------------------------------------------------- 1 | 2 | All tests succeeded. 3 | -------------------------------------------------------------------------------- /testsuite/tests/basic-more/tbuffer.reference: -------------------------------------------------------------------------------- 1 | 0 1 2 | All tests succeeded. 3 | -------------------------------------------------------------------------------- /testsuite/tests/basic-more/testrandom.ml: -------------------------------------------------------------------------------- 1 | open Random 2 | 3 | let _ = 4 | for i = 0 to 20 do 5 | print_float (float 1000.); print_char ' ' 6 | done; 7 | print_newline (); print_newline (); 8 | for i = 0 to 20 do 9 | print_int (int 1000); print_char ' ' 10 | done 11 | 12 | let _ = exit 0 13 | 14 | -------------------------------------------------------------------------------- /testsuite/tests/basic-more/testrandom.reference: -------------------------------------------------------------------------------- 1 | 270.251355065 597.822945853 287.052171181 625.315015859 241.029649126 559.742196387 932.074421229 756.637587326 360.006556146 987.177314953 190.217751234 758.516786217 59.8488223602 328.350439075 172.627051105 944.543207513 629.424106752 868.196647048 174.382120878 78.1259713643 34.3270777955 2 | 3 | 683 782 740 270 835 136 791 168 324 222 156 835 328 636 233 153 671 69 95 357 92 4 | All tests succeeded. 5 | -------------------------------------------------------------------------------- /testsuite/tests/basic-more/tformat.reference: -------------------------------------------------------------------------------- 1 | 0 2 | All tests succeeded. 3 | -------------------------------------------------------------------------------- /testsuite/tests/basic-more/tprintf.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/tests/basic-more/tprintf.ml -------------------------------------------------------------------------------- /testsuite/tests/basic-more/tprintf.reference: -------------------------------------------------------------------------------- 1 | 0 1 2 3 4 5 2 | All tests succeeded. 3 | -------------------------------------------------------------------------------- /testsuite/tests/basic-multdef/Makefile: -------------------------------------------------------------------------------- 1 | MODULES=multdef 2 | MAIN_MODULE=usemultdef 3 | 4 | include ../../makefiles/Makefile.one 5 | include ../../makefiles/Makefile.common 6 | -------------------------------------------------------------------------------- /testsuite/tests/basic-multdef/multdef.ml: -------------------------------------------------------------------------------- 1 | let f x = x + 1 2 | external g : string -> int = "caml_int_of_string" 3 | -------------------------------------------------------------------------------- /testsuite/tests/basic-multdef/multdef.mli: -------------------------------------------------------------------------------- 1 | val f : int -> int 2 | val f : int -> int 3 | val g : string -> int 4 | -------------------------------------------------------------------------------- /testsuite/tests/basic-multdef/usemultdef.ml: -------------------------------------------------------------------------------- 1 | let _ = print_int(Multdef.f 1); print_newline(); exit 0 2 | -------------------------------------------------------------------------------- /testsuite/tests/basic-multdef/usemultdef.reference: -------------------------------------------------------------------------------- 1 | 2 2 | -------------------------------------------------------------------------------- /testsuite/tests/basic-private/Makefile: -------------------------------------------------------------------------------- 1 | MODULES=length 2 | MAIN_MODULE=tlength 3 | 4 | include ../../makefiles/Makefile.one 5 | include ../../makefiles/Makefile.common 6 | -------------------------------------------------------------------------------- /testsuite/tests/basic-private/length.ml: -------------------------------------------------------------------------------- 1 | (* $Id$ 2 | 3 | A testbed file for private type abbreviation definitions. 4 | 5 | We define a Length module to implement positive integers. 6 | 7 | *) 8 | 9 | type t = int;; 10 | 11 | let make x = 12 | if x >= 0 then x else 13 | failwith (Printf.sprintf "cannot build negative length : %i" x) 14 | ;; 15 | 16 | external from : t -> int = "%identity";; 17 | -------------------------------------------------------------------------------- /testsuite/tests/basic-private/length.mli: -------------------------------------------------------------------------------- 1 | (* $Id$ 2 | 3 | A testbed file for private type abbreviation definitions. 4 | 5 | We define a Length module to implement positive integers. 6 | 7 | *) 8 | 9 | type t = private int;; 10 | 11 | val make : int -> t;; 12 | 13 | external from : t -> int = "%identity";; 14 | -------------------------------------------------------------------------------- /testsuite/tests/basic-private/tlength.reference: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/tests/basic-private/tlength.reference -------------------------------------------------------------------------------- /testsuite/tests/basic/Makefile: -------------------------------------------------------------------------------- 1 | include ../../makefiles/Makefile.several 2 | include ../../makefiles/Makefile.common 3 | -------------------------------------------------------------------------------- /testsuite/tests/basic/arrays.reference: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/tests/basic/arrays.reference -------------------------------------------------------------------------------- /testsuite/tests/basic/bigints.ml: -------------------------------------------------------------------------------- 1 | let _ = 2 | print_int 1000000000; print_newline(); 3 | print_int 10000000000; print_newline(); 4 | print_int 100000000000; print_newline(); 5 | print_int 1000000000000; print_newline(); 6 | print_int 10000000000000; print_newline(); 7 | print_int 100000000000000; print_newline(); 8 | print_int 1000000000000000; print_newline(); 9 | print_int 10000000000000000; print_newline(); 10 | print_int 100000000000000000; print_newline(); 11 | print_int 1000000000000000000; print_newline() 12 | 13 | -------------------------------------------------------------------------------- /testsuite/tests/basic/bigints.reference: -------------------------------------------------------------------------------- 1 | 1000000000 2 | 10000000000 3 | 100000000000 4 | 1000000000000 5 | 10000000000000 6 | 100000000000000 7 | 1000000000000000 8 | 10000000000000000 9 | 100000000000000000 10 | 1000000000000000000 11 | -------------------------------------------------------------------------------- /testsuite/tests/basic/float.ml: -------------------------------------------------------------------------------- 1 | Printf.printf "1./.0. = %f\n" (1.0 /. 0.0);; 2 | -------------------------------------------------------------------------------- /testsuite/tests/basic/float.reference: -------------------------------------------------------------------------------- 1 | 1./.0. = inf 2 | -------------------------------------------------------------------------------- /testsuite/tests/basic/includestruct.reference: -------------------------------------------------------------------------------- 1 | 1, 2 2 | 2, 3 3 | 124, 457 4 | 0 5 | 2 6 | 2 7 | 1 8 | 3 9 | F is called 10 | A 11 | 42 12 | A 13 | 42 14 | foo1 15 | foo1 16 | -------------------------------------------------------------------------------- /testsuite/tests/basic/maps.reference: -------------------------------------------------------------------------------- 1 | Union+concat 2 | 3 X1 3 | 4 YY 4 | 5 X2 5 | Inter 6 | 4 Y 7 | -------------------------------------------------------------------------------- /testsuite/tests/basic/recvalues.reference: -------------------------------------------------------------------------------- 1 | Test 1: passed 2 | Test 2: passed 3 | Test 3: passed 4 | foo 5 | Test 4: passed 6 | -------------------------------------------------------------------------------- /testsuite/tests/basic/sets.reference: -------------------------------------------------------------------------------- 1 | -10 true false 2 | -9 false false 3 | -8 false false 4 | -7 false true 5 | -6 false false 6 | -5 false false 7 | -4 false false 8 | -3 false true 9 | -2 true false 10 | -1 false false 11 | 0 true false 12 | 1 false true 13 | 2 true false 14 | 3 false false 15 | 4 true false 16 | 5 false true 17 | 6 true false 18 | 7 false false 19 | 8 false false 20 | 9 false true 21 | 10 false false 22 | false 23 | true 24 | true 25 | false 26 | -------------------------------------------------------------------------------- /testsuite/tests/basic/tailcalls.reference: -------------------------------------------------------------------------------- 1 | 10000001 2 | 10000001 3 | 10000001 4 | 11 5 | 11 6 | -------------------------------------------------------------------------------- /testsuite/tests/callback/reference: -------------------------------------------------------------------------------- 1 | 7 2 | 7 3 | 7 4 | 7 5 | 7 6 | aaaaa 7 | aaaaa 8 | bbbbb 9 | -------------------------------------------------------------------------------- /testsuite/tests/embedded/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . < 2 | #include 3 | #include 4 | 5 | /* Functions callable directly from C */ 6 | 7 | int fib(int n) 8 | { 9 | value * fib_closure = caml_named_value("fib"); 10 | return Int_val(callback(*fib_closure, Val_int(n))); 11 | } 12 | 13 | char * format_result(int n) 14 | { 15 | value * format_result_closure = caml_named_value("format_result"); 16 | return strdup(String_val(callback(*format_result_closure, Val_int(n)))); 17 | } 18 | -------------------------------------------------------------------------------- /testsuite/tests/embedded/program.reference: -------------------------------------------------------------------------------- 1 | Initializing Caml code... 2 | Back in C code... 3 | Computing fib(20)... 4 | Result = 10946 5 | -------------------------------------------------------------------------------- /testsuite/tests/gc-roots/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . < string = "stub1" 2 | 3 | 4 | let () = print_endline (stub1 ()) 5 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-bytecode/plug2.ml: -------------------------------------------------------------------------------- 1 | external stub2: unit -> unit = "stub2" 2 | 3 | 4 | let () = stub2 () 5 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-bytecode/static.reference: -------------------------------------------------------------------------------- 1 | ABCDEF 2 | This is stub1! 3 | This is stub2, calling stub1: 4 | This is stub1! 5 | Ok! 6 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-bytecode/stub1.c: -------------------------------------------------------------------------------- 1 | #include "caml/mlvalues.h" 2 | #include "caml/memory.h" 3 | #include "caml/alloc.h" 4 | #include 5 | 6 | value stub1() { 7 | CAMLlocal1(x); 8 | printf("This is stub1!\n"); 9 | x = caml_copy_string("ABCDEF"); 10 | return x; 11 | } 12 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-bytecode/stub2.c: -------------------------------------------------------------------------------- 1 | #include "caml/mlvalues.h" 2 | #include "caml/memory.h" 3 | #include "caml/alloc.h" 4 | #include 5 | 6 | extern value stub1(); 7 | 8 | value stub2() { 9 | printf("This is stub2, calling stub1:\n"); 10 | stub1(); 11 | printf("Ok!\n"); 12 | return Val_unit; 13 | } 14 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-csharp/bytecode.reference: -------------------------------------------------------------------------------- 1 | Now starting the Caml engine. 2 | Main is running. 3 | Loading ../../../otherlibs/bigarray/bigarray.cma 4 | I'm the plugin. 5 | Loading plugin.cmo 6 | I'm the plugin. 7 | OK. 8 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-csharp/entry.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | __declspec(dllexport) void __stdcall start_caml_engine() { 9 | char * argv[2]; 10 | argv[0] = "--"; 11 | argv[1] = NULL; 12 | caml_startup(argv); 13 | } 14 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-csharp/main.cs: -------------------------------------------------------------------------------- 1 | using System.Runtime.InteropServices; 2 | 3 | public class M { 4 | [DllImport("main.dll")] 5 | public static extern void start_caml_engine(); 6 | 7 | public static void Main() { 8 | System.Console.WriteLine("Now starting the Caml engine."); 9 | start_caml_engine(); 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-csharp/native.reference: -------------------------------------------------------------------------------- 1 | Now starting the Caml engine. 2 | Main is running. 3 | Loading ../../../otherlibs/bigarray/bigarray.cmxs 4 | I'm the plugin. 5 | Loading plugin.cmxs 6 | I'm the plugin. 7 | OK. 8 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-csharp/plugin.ml: -------------------------------------------------------------------------------- 1 | let f x = x.{2} 2 | 3 | let () = 4 | print_endline "I'm the plugin." 5 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . < f ()) !cbs 16 | 17 | let () = 18 | at_exit runall 19 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/b.ml: -------------------------------------------------------------------------------- 1 | let () = 2 | print_endline "B is running"; 3 | incr A.x; 4 | Printf.printf "A.x = %i\n" !A.x 5 | 6 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/bug.ml: -------------------------------------------------------------------------------- 1 | let () = try raise (Invalid_argument "X") with Invalid_argument s -> 2 | raise (Invalid_argument (s ^ s)) 3 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/c.ml: -------------------------------------------------------------------------------- 1 | let () = 2 | print_endline "C is running"; 3 | incr A.x; 4 | Printf.printf "A.x = %i\n" !A.x 5 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/factorial.c: -------------------------------------------------------------------------------- 1 | #include "caml/mlvalues.h" 2 | #include "caml/memory.h" 3 | #include "caml/alloc.h" 4 | #include 5 | 6 | value factorial(value n){ 7 | CAMLparam1(n); 8 | CAMLlocal1(s); 9 | 10 | static char buf[256]; 11 | int x = 1; 12 | int i; 13 | int m = Int_val(n); 14 | for (i = 1; i <= m; i++) x *= i; 15 | sprintf(buf,"%i",x); 16 | s = copy_string(buf); 17 | CAMLreturn (s); 18 | } 19 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/pack_client.ml: -------------------------------------------------------------------------------- 1 | let () = 2 | print_endline Mypack.Packed1.mykey 3 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/packed1.ml: -------------------------------------------------------------------------------- 1 | let () = 2 | Api.reg_mod "Packed1" 3 | 4 | let bla = Sys.argv.(0) ^ "XXX" 5 | let mykey = Sys.argv.(0) 6 | 7 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/packed1_client.ml: -------------------------------------------------------------------------------- 1 | let () = 2 | Api.reg_mod "Packed1_client"; 3 | print_endline Packed1.mykey 4 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/plugin.ml: -------------------------------------------------------------------------------- 1 | let rec f x = ignore ([x]); f x 2 | 3 | let rec fact n = if n = 0 then 1 else n * fact (n - 1) 4 | 5 | let facts = [ fact 1; fact 2; fact 3; fact (Random.int 4) ] 6 | 7 | let () = 8 | Api.reg_mod "Plugin"; 9 | print_endline "COUCOU"; 10 | () 11 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/plugin.mli: -------------------------------------------------------------------------------- 1 | val facts: int list 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/plugin2.ml: -------------------------------------------------------------------------------- 1 | (*external ex: int -> int = "caml_ex"*) 2 | 3 | let () = 4 | Api.reg_mod "Plugin2"; 5 | (* let i = ex 3 in*) 6 | List.iter (fun i -> Printf.printf "%i\n" i) Plugin.facts; 7 | Printf.printf "XXX\n"; 8 | raise Exit 9 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/plugin4.ml: -------------------------------------------------------------------------------- 1 | let () = 2 | Printf.printf "time = %f\n" (Unix.time ()); 3 | Api.reg_mod "Plugin" 4 | 5 | 6 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/plugin_ext.ml: -------------------------------------------------------------------------------- 1 | external fact: int -> string = "factorial" 2 | 3 | let () = 4 | Api.reg_mod "plugin_ext"; 5 | Printf.printf "fact 10 = %s\n" (fact 10) 6 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/plugin_high_arity.ml: -------------------------------------------------------------------------------- 1 | let f x x x x x x x x x x x x x = () 2 | 3 | let g x = f x x x x x x x x 4 | 5 | let () = 6 | Api.reg_mod "HA" 7 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/plugin_ref.ml: -------------------------------------------------------------------------------- 1 | let x = ref 0 2 | 3 | let () = 4 | Api.reg_mod "Plugin_ref"; 5 | 6 | Api.add_cb 7 | (fun () -> 8 | Printf.printf "current value for ref = %i\n" !x; 9 | incr x 10 | ) 11 | 12 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/plugin_simple.ml: -------------------------------------------------------------------------------- 1 | let facts = [ (Random.int 4) ] 2 | 3 | let () = print_endline "COUCOU"; print_char '\n' 4 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/plugin_thread.ml: -------------------------------------------------------------------------------- 1 | let () = 2 | Api.reg_mod "Plugin_thread"; 3 | let _t = 4 | Thread.create 5 | (fun () -> 6 | for i = 1 to 5 do 7 | print_endline "Thread"; flush stdout; 8 | Thread.delay 1.; 9 | done 10 | ) () 11 | in 12 | for i = 1 to 10 do 13 | print_endline "Thread"; flush stdout; 14 | Thread.delay 0.50; 15 | done 16 | 17 | 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/reference: -------------------------------------------------------------------------------- 1 | Loading plugin_thread.so 2 | Registering module Plugin_thread 3 | Thread 4 | Thread 5 | Thread 6 | Thread 7 | Thread 8 | Thread 9 | Thread 10 | Thread 11 | Thread 12 | Thread 13 | Thread 14 | Thread 15 | Thread 16 | Thread 17 | Thread 18 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/sub/api.ml: -------------------------------------------------------------------------------- 1 | let f i = 2 | Printf.printf "Sub/api: f called with %i\n" i; 3 | i + 1 4 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/sub/api.mli: -------------------------------------------------------------------------------- 1 | val f : int -> int 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/sub/plugin.ml: -------------------------------------------------------------------------------- 1 | let rec fact n = if n = 0 then 1 else n * fact (n - 1) 2 | 3 | let facts = [ fact 1; fact 2; fact 3; fact 4; fact 5 ] 4 | 5 | let () = 6 | Api.reg_mod "Plugin'" 7 | 8 | -------------------------------------------------------------------------------- /testsuite/tests/lib-dynlink-native/sub/plugin3.ml: -------------------------------------------------------------------------------- 1 | let () = 2 | ignore (Api.f 10) 3 | 4 | -------------------------------------------------------------------------------- /testsuite/tests/lib-marshal/Makefile: -------------------------------------------------------------------------------- 1 | #MODULES= 2 | MAIN_MODULE=intext 3 | C_FILES=intextaux 4 | 5 | include ../../makefiles/Makefile.one 6 | include ../../makefiles/Makefile.common 7 | -------------------------------------------------------------------------------- /testsuite/tests/lib-marshal/intextaux.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | value marshal_to_block(value vbuf, value vlen, value v, value vflags) 5 | { 6 | return Val_long(output_value_to_block(v, vflags, 7 | (char *) vbuf, Long_val(vlen))); 8 | } 9 | 10 | value marshal_from_block(value vbuf, value vlen) 11 | { 12 | return input_value_from_block((char *) vbuf, Long_val(vlen)); 13 | } 14 | -------------------------------------------------------------------------------- /testsuite/tests/lib-num-2/Makefile: -------------------------------------------------------------------------------- 1 | LIBRARIES=nums 2 | PROGRAM_ARGS=1000 3 | 4 | include ../../makefiles/Makefile.several 5 | include ../../makefiles/Makefile.common 6 | -------------------------------------------------------------------------------- /testsuite/tests/lib-num/Makefile: -------------------------------------------------------------------------------- 1 | MODULES=test test_nats test_big_ints test_ratios test_nums test_io 2 | MAIN_MODULE=end_test 3 | ADD_COMPFLAGS=-w a 4 | LIBRARIES=nums 5 | 6 | include ../../makefiles/Makefile.one 7 | include ../../makefiles/Makefile.common 8 | -------------------------------------------------------------------------------- /testsuite/tests/lib-num/end_test.ml: -------------------------------------------------------------------------------- 1 | Test.end_tests ();; 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-scanf-2/reference: -------------------------------------------------------------------------------- 1 | Ping-pong Ping-pong Ping-pong Ping-pong Ping-pong Ping-pong Ping-pong Ping-pong! 2 | Test OK. 3 | -------------------------------------------------------------------------------- /testsuite/tests/lib-scanf/Makefile: -------------------------------------------------------------------------------- 1 | #MODULES= 2 | MAIN_MODULE=tscanf 3 | ADD_COMPFLAGS=-I $(BASEDIR)/lib 4 | ADD_MODULES=testing 5 | 6 | include ../../makefiles/Makefile.one 7 | include ../../makefiles/Makefile.common 8 | -------------------------------------------------------------------------------- /testsuite/tests/lib-scanf/tscanf.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/tests/lib-scanf/tscanf.ml -------------------------------------------------------------------------------- /testsuite/tests/lib-scanf/tscanf.reference: -------------------------------------------------------------------------------- 1 | 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 2 | All tests succeeded. 3 | -------------------------------------------------------------------------------- /testsuite/tests/lib-scanf/tscanf_data: -------------------------------------------------------------------------------- 1 | "Objective" -> "Caml"; 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-str/Makefile: -------------------------------------------------------------------------------- 1 | LIBRARIES=str 2 | 3 | include ../../makefiles/Makefile.several 4 | include ../../makefiles/Makefile.common 5 | -------------------------------------------------------------------------------- /testsuite/tests/lib-str/t01.ml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/tests/lib-str/t01.ml -------------------------------------------------------------------------------- /testsuite/tests/lib-str/t01.reference: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/tests/lib-str/t01.reference -------------------------------------------------------------------------------- /testsuite/tests/lib-systhreads/Makefile: -------------------------------------------------------------------------------- 1 | LIBRARIES=unix threads 2 | ADD_COMPFLAGS=-thread 3 | 4 | include ../../makefiles/Makefile.several 5 | include ../../makefiles/Makefile.common 6 | -------------------------------------------------------------------------------- /testsuite/tests/lib-systhreads/testfork.reference: -------------------------------------------------------------------------------- 1 | Forking... 2 | In parent... 3 | In child... 4 | Child did minor GC. 5 | Child is exiting. 6 | Parent is exiting. 7 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/.cvsignore: -------------------------------------------------------------------------------- 1 | *.byt 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/Makefile: -------------------------------------------------------------------------------- 1 | LIBRARIES=unix threads 2 | ADD_COMPFLAGS=-thread 3 | 4 | include ../../makefiles/Makefile.several 5 | include ../../makefiles/Makefile.common 6 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/close.ml: -------------------------------------------------------------------------------- 1 | let main () = 2 | let (rd, wr) = Unix.pipe() in 3 | let _ = Thread.create 4 | (fun () -> 5 | ignore (Unix.write wr "0123456789" 0 10); 6 | Thread.delay 3.0; 7 | print_endline "closing fd..."; 8 | Unix.close rd) 9 | () in 10 | let buf = String.create 10 in 11 | print_endline "reading..."; 12 | ignore (Unix.read rd buf 0 10); 13 | print_endline "read returned" 14 | 15 | let _ = Unix.handle_unix_error main () 16 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/close.reference: -------------------------------------------------------------------------------- 1 | reading... 2 | read returned 3 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test1.checker: -------------------------------------------------------------------------------- 1 | sort test1.result | diff -q test1.reference - 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test2.checker: -------------------------------------------------------------------------------- 1 | sed -e 1q test2.result | grep -q '^[ab]*' 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test2.ml: -------------------------------------------------------------------------------- 1 | let yield = ref false 2 | 3 | let print_message c = 4 | for i = 1 to 10000 do 5 | print_char c; flush stdout; 6 | if !yield then Thread.yield() 7 | done 8 | 9 | let _ = yield := (Array.length Sys.argv > 1) 10 | let t1 = Thread.create print_message 'a' 11 | let t2 = Thread.create print_message 'b' 12 | let _ = Thread.join t1 13 | let _ = Thread.join t2 14 | 15 | ;; 16 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test3.checker: -------------------------------------------------------------------------------- 1 | sed -e 1q test3.result | grep -q '^[ab]*' 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test3.ml: -------------------------------------------------------------------------------- 1 | let print_message delay c = 2 | while true do 3 | print_char c; flush stdout; Thread.delay delay 4 | done 5 | 6 | let _ = 7 | Thread.create (print_message 0.6666666666) 'a'; 8 | print_message 1.0 'b' 9 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test3.runner: -------------------------------------------------------------------------------- 1 | ./program > test3.result & 2 | pid=$! 3 | sleep 5 4 | kill -9 $pid -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test4.checker: -------------------------------------------------------------------------------- 1 | sort -u test4.result | diff -q test4.reference - 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test4.data: -------------------------------------------------------------------------------- 1 | abc 2 | def 3 | ghi 4 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test4.reference: -------------------------------------------------------------------------------- 1 | 317811 2 | >> abc 3 | >> def 4 | >> ghi 5 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test4.runner: -------------------------------------------------------------------------------- 1 | ./program < test4.data > test4.result 2> /dev/null || true -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test5.checker: -------------------------------------------------------------------------------- 1 | sort -u test5.result | diff -q test5.reference - 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test5.ml: -------------------------------------------------------------------------------- 1 | open Event 2 | 3 | let ch = (new_channel() : string channel) 4 | 5 | let rec sender msg = 6 | sync (send ch msg); 7 | sender msg 8 | 9 | let rec receiver name = 10 | print_string (name ^ ": " ^ sync (receive ch) ^ "\n"); 11 | flush stdout; 12 | receiver name 13 | 14 | let _ = 15 | Thread.create sender "hello"; 16 | Thread.create sender "world"; 17 | Thread.create receiver "A"; 18 | receiver "B"; 19 | exit 0 20 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test5.reference: -------------------------------------------------------------------------------- 1 | A: hello 2 | A: world 3 | B: hello 4 | B: world 5 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test5.runner: -------------------------------------------------------------------------------- 1 | ./program > test5.result & 2 | pid=$! 3 | sleep 1 4 | kill -9 $pid -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test6.checker: -------------------------------------------------------------------------------- 1 | sort -u test6.result | diff -q test6.reference - 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test6.ml: -------------------------------------------------------------------------------- 1 | open Event 2 | 3 | let ch = (new_channel() : string channel) 4 | 5 | let rec f tag msg = 6 | select [ 7 | send ch msg; 8 | wrap (receive ch) (fun x -> print_string(tag ^ ": " ^ x); print_newline()) 9 | ]; 10 | f tag msg 11 | 12 | let _ = 13 | Thread.create (f "A") "hello"; 14 | f "B" "world"; 15 | exit 0 16 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test6.reference: -------------------------------------------------------------------------------- 1 | A: world 2 | B: hello 3 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test6.runner: -------------------------------------------------------------------------------- 1 | ./program > test6.result & 2 | pid=$! 3 | sleep 1 4 | kill -9 $pid 5 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test7.checker: -------------------------------------------------------------------------------- 1 | test `grep -E '^-?[0123456789]+$' test7.result | wc -l` = `cat test7.result | wc -l` -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test7.runner: -------------------------------------------------------------------------------- 1 | ./program > test7.result & 2 | pid=$! 3 | sleep 1 4 | kill -9 $pid 5 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test8.reference: -------------------------------------------------------------------------------- 1 | 3 2 | un 3 | deux 4 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/test9.reference: -------------------------------------------------------------------------------- 1 | g F 2 | f G 3 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testA.checker: -------------------------------------------------------------------------------- 1 | sort testA.result | diff -q testA.reference - 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testA.reference: -------------------------------------------------------------------------------- 1 | 1 --> un 2 | 2 --> deux 3 | 3 --> trois 4 | 4 --> quatre 5 | 5 --> cinq 6 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testexit.checker: -------------------------------------------------------------------------------- 1 | sort testexit.result | diff -q testexit.reference - 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testexit.reference: -------------------------------------------------------------------------------- 1 | A exiting 2 | A: 1 3 | A: 2 4 | A: 3 5 | A: 4 6 | B exiting 7 | B: 1 8 | B: 2 9 | B: 3 10 | B: 4 11 | B: 5 12 | B: 6 13 | B: 7 14 | C exiting 15 | C: 1 16 | C: 10 17 | C: 2 18 | C: 3 19 | C: 4 20 | C: 5 21 | C: 6 22 | C: 7 23 | C: 8 24 | C: 9 25 | Main exiting 26 | Main: 1 27 | Main: 2 28 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testsignal.checker: -------------------------------------------------------------------------------- 1 | sed -e 1q testsignal.result | grep -q '^[ab]*Got ctrl-C, exiting...$' 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testsignal.ml: -------------------------------------------------------------------------------- 1 | let sighandler _ = 2 | print_string "Got ctrl-C, exiting..."; print_newline(); 3 | exit 0 4 | 5 | let print_message delay c = 6 | while true do 7 | print_char c; flush stdout; Thread.delay delay 8 | done 9 | 10 | let _ = 11 | Sys.signal Sys.sigint (Sys.Signal_handle sighandler); 12 | Thread.create (print_message 0.6666666666) 'a'; 13 | print_message 1.0 'b' 14 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testsignal.runner: -------------------------------------------------------------------------------- 1 | ./program > testsignal.result & 2 | pid=$! 3 | sleep 3 4 | kill -INT $pid -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testsignal2.checker: -------------------------------------------------------------------------------- 1 | sed -e 1q testsignal2.result | grep -q '^[ab]*' 2 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testsignal2.ml: -------------------------------------------------------------------------------- 1 | let print_message delay c = 2 | while true do 3 | print_char c; flush stdout; Thread.delay delay 4 | done 5 | 6 | let _ = 7 | Thread.sigmask Unix.SIG_BLOCK [Sys.sigint; Sys.sigterm]; 8 | let th1 = Thread.create (print_message 0.6666666666) 'a' in 9 | let th2 = Thread.create (print_message 1.0) 'b' in 10 | let s = Thread.wait_signal [Sys.sigint; Sys.sigterm] in 11 | Printf.printf "Got signal %d, exiting...\n" s 12 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testsignal2.runner: -------------------------------------------------------------------------------- 1 | ./program > testsignal2.result & 2 | pid=$! 3 | sleep 3 4 | kill -INT $pid 5 | sleep 1 6 | kill -9 $pid || true 7 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/testsocket.reference: -------------------------------------------------------------------------------- 1 | 0> connecting 2 | 0> connected 3 | 0> data retrieved 4 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/token1.reference: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/tests/lib-threads/token1.reference -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/token2.reference: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/testsuite/tests/lib-threads/token2.reference -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/torture.data: -------------------------------------------------------------------------------- 1 | abc 2 | def 3 | ghi 4 | -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/torture.reference: -------------------------------------------------------------------------------- 1 | > >>> abc 2 | > >>> def 3 | > >>> ghi 4 | > -------------------------------------------------------------------------------- /testsuite/tests/lib-threads/torture.runner: -------------------------------------------------------------------------------- 1 | ./program < torture.data > torture.result 2> /dev/null || true -------------------------------------------------------------------------------- /testsuite/tests/misc-kb/Makefile: -------------------------------------------------------------------------------- 1 | MODULES=terms equations orderings kb 2 | MAIN_MODULE=kbmain 3 | ADD_COMPFLAGS=-w a 4 | 5 | include ../../makefiles/Makefile.one 6 | include ../../makefiles/Makefile.common 7 | -------------------------------------------------------------------------------- /testsuite/tests/misc-unsafe/Makefile: -------------------------------------------------------------------------------- 1 | UNSAFE=ON 2 | include ../../makefiles/Makefile.several 3 | include ../../makefiles/Makefile.common 4 | -------------------------------------------------------------------------------- /testsuite/tests/misc-unsafe/almabench.reference: -------------------------------------------------------------------------------- 1 | 0 17.00 -26.06 2 | 1 12.34 1.29 3 | 2 6.83 22.95 4 | 3 0.04 -1.26 5 | 4 2.30 12.54 6 | 5 2.93 14.35 7 | 6 21.27 -16.57 8 | 7 20.41 -19.04 9 | -------------------------------------------------------------------------------- /testsuite/tests/misc-unsafe/fft.reference: -------------------------------------------------------------------------------- 1 | 16... ok 2 | 32... ok 3 | 64... ok 4 | 128... ok 5 | 256... ok 6 | 512... ok 7 | 1024... ok 8 | 2048... ok 9 | 4096... ok 10 | 8192... ok 11 | 16384... ok 12 | 32768... ok 13 | 65536... ok 14 | 131072... ok 15 | 262144... ok 16 | 524288... ok 17 | -------------------------------------------------------------------------------- /testsuite/tests/misc-unsafe/quicksort.reference: -------------------------------------------------------------------------------- 1 | OK 2 | OK 3 | -------------------------------------------------------------------------------- /testsuite/tests/misc/Makefile: -------------------------------------------------------------------------------- 1 | include ../../makefiles/Makefile.several 2 | include ../../makefiles/Makefile.common 3 | -------------------------------------------------------------------------------- /testsuite/tests/misc/bdd.reference: -------------------------------------------------------------------------------- 1 | OK 2 | -------------------------------------------------------------------------------- /testsuite/tests/misc/boyer.reference: -------------------------------------------------------------------------------- 1 | Proved! 2 | -------------------------------------------------------------------------------- /testsuite/tests/misc/fib.reference: -------------------------------------------------------------------------------- 1 | 165580141 2 | -------------------------------------------------------------------------------- /testsuite/tests/misc/nucleic.reference: -------------------------------------------------------------------------------- 1 | 33.7976 2 | -------------------------------------------------------------------------------- /testsuite/tests/misc/takc.reference: -------------------------------------------------------------------------------- 1 | 14000 2 | -------------------------------------------------------------------------------- /testsuite/tests/misc/taku.reference: -------------------------------------------------------------------------------- 1 | 14000 2 | -------------------------------------------------------------------------------- /testsuite/tests/misc/weaktest.reference: -------------------------------------------------------------------------------- 1 | pass 2 | -------------------------------------------------------------------------------- /testsuite/tests/regression-camlp4-class-type-plus/Makefile: -------------------------------------------------------------------------------- 1 | ADD_COMPFLAGS = -pp 'camlp4o' 2 | MAIN_MODULE = camlp4_class_type_plus_ok 3 | 4 | include ../../makefiles/Makefile.okbad 5 | include ../../makefiles/Makefile.common 6 | -------------------------------------------------------------------------------- /testsuite/tests/regression-camlp4-class-type-plus/camlp4_class_type_plus_ok.ml: -------------------------------------------------------------------------------- 1 | type t;; 2 | type xdr_value;; 3 | 4 | class type [ 't ] engine = object 5 | end;; 6 | 7 | module type T = sig 8 | class unbound_async_call : t -> [xdr_value] engine;; 9 | end;; 10 | -------------------------------------------------------------------------------- /testsuite/tests/regression-pr5080-notes/Makefile: -------------------------------------------------------------------------------- 1 | ADD_COMPFLAGS = -pp 'camlp4o pa_macro.cmo' 2 | MAIN_MODULE = pr5080_notes_ok 3 | 4 | include ../../makefiles/Makefile.okbad 5 | include ../../makefiles/Makefile.common 6 | -------------------------------------------------------------------------------- /testsuite/tests/regression-pr5080-notes/pr5080_notes_ok.ml: -------------------------------------------------------------------------------- 1 | let marshal_int f = 2 | match [] with 3 | | _ :: `INT n :: _ -> f n 4 | | _ -> failwith "marshal_int" 5 | -------------------------------------------------------------------------------- /testsuite/tests/runtime-errors/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . < 0 3 | then 1 + f (x + 1) 4 | else 5 | try 6 | 1 + f (x + 1) 7 | with Stack_overflow -> 8 | print_string "x = "; print_int x; print_newline(); 9 | raise Stack_overflow 10 | 11 | let _ = 12 | try 13 | ignore(f 0) 14 | with Stack_overflow -> 15 | print_string "Stack overflow caught"; print_newline() 16 | -------------------------------------------------------------------------------- /testsuite/tests/runtime-errors/syserror.bytecode.reference: -------------------------------------------------------------------------------- 1 | Fatal error: exception Sys_error("titi:/toto: No such file or directory") 2 | -------------------------------------------------------------------------------- /testsuite/tests/runtime-errors/syserror.ml: -------------------------------------------------------------------------------- 1 | let channel = open_out "titi:/toto" 2 | -------------------------------------------------------------------------------- /testsuite/tests/runtime-errors/syserror.native.reference: -------------------------------------------------------------------------------- 1 | Fatal error: exception Sys_error("titi:/toto: No such file or directory") 2 | -------------------------------------------------------------------------------- /testsuite/tests/tool-lexyacc/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . <(1, 0) 5 | 2 ATOM0 6 | 3 SETGLOBAL T050-getglobal 7 | 5 STOP 8 | **) 9 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t050-pushgetglobal.ml: -------------------------------------------------------------------------------- 1 | let _ = () in 0.01;; 2 | 3 | (** 4 | 0 CONST0 5 | 1 PUSHGETGLOBAL 0.01 6 | 3 POP 1 7 | 5 ATOM0 8 | 6 SETGLOBAL T050-pushgetglobal 9 | 8 STOP 10 | **) 11 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t051-getglobalfield.ml: -------------------------------------------------------------------------------- 1 | Lib.x;; 2 | 3 | (** 4 | 0 CONSTINT 42 5 | 2 PUSHACC0 6 | 3 MAKEBLOCK1 0 7 | 5 POP 1 8 | 7 SETGLOBAL Lib 9 | 9 GETGLOBALFIELD Lib, 0 10 | 12 ATOM0 11 | 13 SETGLOBAL T051-getglobalfield 12 | 15 STOP 13 | **) 14 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t051-pushgetglobalfield.ml: -------------------------------------------------------------------------------- 1 | let _ = () in Lib.x;; 2 | 3 | (** 4 | 0 CONSTINT 42 5 | 2 PUSHACC0 6 | 3 MAKEBLOCK1 0 7 | 5 POP 1 8 | 7 SETGLOBAL Lib 9 | 9 CONST0 10 | 10 PUSHGETGLOBALFIELD Lib, 0 11 | 13 POP 1 12 | 15 ATOM0 13 | 16 SETGLOBAL T051-pushgetglobalfield 14 | 18 STOP 15 | **) 16 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t060-raise.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | raise End_of_file;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 GETGLOBAL End_of_file 11 | 11 MAKEBLOCK1 0 12 | 13 RAISE 13 | 14 SETGLOBAL T060-raise 14 | 16 STOP 15 | **) 16 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t070-branch.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if true then 0 else raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST1 11 | 10 BRANCHIFNOT 15 12 | 12 CONST0 13 | 13 BRANCH 20 14 | 15 GETGLOBAL Not_found 15 | 17 MAKEBLOCK1 0 16 | 19 RAISE 17 | 20 ATOM0 18 | 21 SETGLOBAL T070-branch 19 | 23 STOP 20 | **) 21 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t070-branchif.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if not false then 0 else raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST0 11 | 10 BRANCHIF 15 12 | 12 CONST0 13 | 13 BRANCH 20 14 | 15 GETGLOBAL Not_found 15 | 17 MAKEBLOCK1 0 16 | 19 RAISE 17 | 20 ATOM0 18 | 21 SETGLOBAL T070-branchif 19 | 23 STOP 20 | **) 21 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t070-branchifnot.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if false then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST0 11 | 10 BRANCHIFNOT 17 12 | 12 GETGLOBAL Not_found 13 | 14 MAKEBLOCK1 0 14 | 16 RAISE 15 | 17 ATOM0 16 | 18 SETGLOBAL T070-branchifnot 17 | 20 STOP 18 | **) 19 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t071-boolnot.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if not true then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST1 11 | 10 BOOLNOT 12 | 11 BRANCHIFNOT 18 13 | 13 GETGLOBAL Not_found 14 | 15 MAKEBLOCK1 0 15 | 17 RAISE 16 | 18 ATOM0 17 | 19 SETGLOBAL T071-boolnot 18 | 21 STOP 19 | **) 20 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t080-eq.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if not (0 = 0) then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST0 11 | 10 PUSHCONST0 12 | 11 EQ 13 | 12 BOOLNOT 14 | 13 BRANCHIFNOT 20 15 | 15 GETGLOBAL Not_found 16 | 17 MAKEBLOCK1 0 17 | 19 RAISE 18 | 20 ATOM0 19 | 21 SETGLOBAL T080-eq 20 | 23 STOP 21 | **) 22 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t080-geint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if not (0 >= 0) then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST0 11 | 10 PUSHCONST0 12 | 11 GEINT 13 | 12 BOOLNOT 14 | 13 BRANCHIFNOT 20 15 | 15 GETGLOBAL Not_found 16 | 17 MAKEBLOCK1 0 17 | 19 RAISE 18 | 20 ATOM0 19 | 21 SETGLOBAL T080-geint 20 | 23 STOP 21 | **) 22 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t080-gtint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if 0 > 0 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST0 11 | 10 PUSHCONST0 12 | 11 GTINT 13 | 12 BRANCHIFNOT 19 14 | 14 GETGLOBAL Not_found 15 | 16 MAKEBLOCK1 0 16 | 18 RAISE 17 | 19 ATOM0 18 | 20 SETGLOBAL T080-gtint 19 | 22 STOP 20 | **) 21 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t080-leint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if not (0 <= 0) then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST0 11 | 10 PUSHCONST0 12 | 11 LEINT 13 | 12 BOOLNOT 14 | 13 BRANCHIFNOT 20 15 | 15 GETGLOBAL Not_found 16 | 17 MAKEBLOCK1 0 17 | 19 RAISE 18 | 20 ATOM0 19 | 21 SETGLOBAL T080-leint 20 | 23 STOP 21 | **) 22 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t080-ltint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if 0 < 0 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST0 11 | 10 PUSHCONST0 12 | 11 LTINT 13 | 12 BRANCHIFNOT 19 14 | 14 GETGLOBAL Not_found 15 | 16 MAKEBLOCK1 0 16 | 18 RAISE 17 | 19 ATOM0 18 | 20 SETGLOBAL T080-ltint 19 | 22 STOP 20 | **) 21 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t080-neq.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if 0 <> 0 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST0 11 | 10 PUSHCONST0 12 | 11 NEQ 13 | 12 BRANCHIFNOT 19 14 | 14 GETGLOBAL Not_found 15 | 16 MAKEBLOCK1 0 16 | 18 RAISE 17 | 19 ATOM0 18 | 20 SETGLOBAL T080-neq 19 | 22 STOP 20 | **) 21 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t092-pushacc0.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | let x = false in 3 | if x then raise Not_found 4 | ;; 5 | 6 | (** 7 | 0 CONSTINT 42 8 | 2 PUSHACC0 9 | 3 MAKEBLOCK1 0 10 | 5 POP 1 11 | 7 SETGLOBAL Lib 12 | 9 CONST0 13 | 10 PUSHACC0 14 | 11 BRANCHIFNOT 18 15 | 13 GETGLOBAL Not_found 16 | 15 MAKEBLOCK1 0 17 | 17 RAISE 18 | 18 POP 1 19 | 20 ATOM0 20 | 21 SETGLOBAL T092-pushacc0 21 | 23 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t100-pushtrap.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | try raise Not_found 3 | with _ -> () 4 | ;; 5 | 6 | (** 7 | 0 CONSTINT 42 8 | 2 PUSHACC0 9 | 3 MAKEBLOCK1 0 10 | 5 POP 1 11 | 7 SETGLOBAL Lib 12 | 9 PUSHTRAP 16 13 | 11 GETGLOBAL Not_found 14 | 13 MAKEBLOCK1 0 15 | 15 RAISE 16 | 16 PUSHCONST0 17 | 17 POP 1 18 | 19 ATOM0 19 | 20 SETGLOBAL T100-pushtrap 20 | 22 STOP 21 | **) 22 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t101-poptrap.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | try () 3 | with _ -> () 4 | ;; 5 | 6 | (** 7 | 0 CONSTINT 42 8 | 2 PUSHACC0 9 | 3 MAKEBLOCK1 0 10 | 5 POP 1 11 | 7 SETGLOBAL Lib 12 | 9 PUSHTRAP 15 13 | 11 CONST0 14 | 12 POPTRAP 15 | 13 BRANCH 18 16 | 15 PUSHCONST0 17 | 16 POP 1 18 | 18 ATOM0 19 | 19 SETGLOBAL T101-poptrap 20 | 21 STOP 21 | **) 22 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-andint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if (3 land 6) <> 2 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST2 11 | 10 PUSHCONSTINT 6 12 | 12 PUSHCONST3 13 | 13 ANDINT 14 | 14 NEQ 15 | 15 BRANCHIFNOT 22 16 | 17 GETGLOBAL Not_found 17 | 19 MAKEBLOCK1 0 18 | 21 RAISE 19 | 22 ATOM0 20 | 23 SETGLOBAL T110-andint 21 | 25 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-asrint-2.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if (3 asr 1) <> 1 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST1 11 | 10 PUSHCONST1 12 | 11 PUSHCONST3 13 | 12 ASRINT 14 | 13 NEQ 15 | 14 BRANCHIFNOT 21 16 | 16 GETGLOBAL Not_found 17 | 18 MAKEBLOCK1 0 18 | 20 RAISE 19 | 21 ATOM0 20 | 22 SETGLOBAL T110-asrint-2 21 | 24 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-divint-1.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if 2 / 2 <> 1 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST1 11 | 10 PUSHCONST2 12 | 11 PUSHCONST2 13 | 12 DIVINT 14 | 13 NEQ 15 | 14 BRANCHIFNOT 21 16 | 16 GETGLOBAL Not_found 17 | 18 MAKEBLOCK1 0 18 | 20 RAISE 19 | 21 ATOM0 20 | 22 SETGLOBAL T110-divint-1 21 | 24 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-divint-2.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if 3 / 2 <> 1 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST1 11 | 10 PUSHCONST2 12 | 11 PUSHCONST3 13 | 12 DIVINT 14 | 13 NEQ 15 | 14 BRANCHIFNOT 21 16 | 16 GETGLOBAL Not_found 17 | 18 MAKEBLOCK1 0 18 | 20 RAISE 19 | 21 ATOM0 20 | 22 SETGLOBAL T110-divint-2 21 | 24 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-lslint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if (3 lsl 2) <> 12 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONSTINT 12 11 | 11 PUSHCONST2 12 | 12 PUSHCONST3 13 | 13 LSLINT 14 | 14 NEQ 15 | 15 BRANCHIFNOT 22 16 | 17 GETGLOBAL Not_found 17 | 19 MAKEBLOCK1 0 18 | 21 RAISE 19 | 22 ATOM0 20 | 23 SETGLOBAL T110-lslint 21 | 25 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-lsrint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if (14 lsr 2) <> 3 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST3 11 | 10 PUSHCONST2 12 | 11 PUSHCONSTINT 14 13 | 13 LSRINT 14 | 14 NEQ 15 | 15 BRANCHIFNOT 22 16 | 17 GETGLOBAL Not_found 17 | 19 MAKEBLOCK1 0 18 | 21 RAISE 19 | 22 ATOM0 20 | 23 SETGLOBAL T110-lsrint 21 | 25 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-modint-1.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if 20 mod 3 <> 2 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST2 11 | 10 PUSHCONST3 12 | 11 PUSHCONSTINT 20 13 | 13 MODINT 14 | 14 NEQ 15 | 15 BRANCHIFNOT 22 16 | 17 GETGLOBAL Not_found 17 | 19 MAKEBLOCK1 0 18 | 21 RAISE 19 | 22 ATOM0 20 | 23 SETGLOBAL T110-modint-1 21 | 25 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-mulint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if 2 * 2 <> 4 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONSTINT 4 11 | 11 PUSHCONST2 12 | 12 PUSHCONST2 13 | 13 MULINT 14 | 14 NEQ 15 | 15 BRANCHIFNOT 22 16 | 17 GETGLOBAL Not_found 17 | 19 MAKEBLOCK1 0 18 | 21 RAISE 19 | 22 ATOM0 20 | 23 SETGLOBAL T110-mulint 21 | 25 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-offsetint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if 2 + 2 <> 4 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONSTINT 4 11 | 11 PUSHCONST2 12 | 12 OFFSETINT 2 13 | 14 NEQ 14 | 15 BRANCHIFNOT 22 15 | 17 GETGLOBAL Not_found 16 | 19 MAKEBLOCK1 0 17 | 21 RAISE 18 | 22 ATOM0 19 | 23 SETGLOBAL T110-offsetint 20 | 25 STOP 21 | **) 22 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-orint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if (3 lor 6) <> 7 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONSTINT 7 11 | 11 PUSHCONSTINT 6 12 | 13 PUSHCONST3 13 | 14 ORINT 14 | 15 NEQ 15 | 16 BRANCHIFNOT 23 16 | 18 GETGLOBAL Not_found 17 | 20 MAKEBLOCK1 0 18 | 22 RAISE 19 | 23 ATOM0 20 | 24 SETGLOBAL T110-orint 21 | 26 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t110-xorint.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | if (3 lxor 6) <> 5 then raise Not_found;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONSTINT 5 11 | 11 PUSHCONSTINT 6 12 | 13 PUSHCONST3 13 | 14 XORINT 14 | 15 NEQ 15 | 16 BRANCHIFNOT 23 16 | 18 GETGLOBAL Not_found 17 | 20 MAKEBLOCK1 0 18 | 22 RAISE 19 | 23 ATOM0 20 | 24 SETGLOBAL T110-xorint 21 | 26 STOP 22 | **) 23 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t150-push-1.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | let _ = 0 in 3 | try 0 with _ -> 0 4 | ;; 5 | 6 | (** 7 | 0 CONSTINT 42 8 | 2 PUSHACC0 9 | 3 MAKEBLOCK1 0 10 | 5 POP 1 11 | 7 SETGLOBAL Lib 12 | 9 CONST0 13 | 10 PUSH 14 | 11 PUSHTRAP 17 15 | 13 CONST0 16 | 14 POPTRAP 17 | 15 BRANCH 20 18 | 17 PUSHCONST0 19 | 18 POP 1 20 | 20 POP 1 21 | 22 ATOM0 22 | 23 SETGLOBAL T150-push-1 23 | 25 STOP 24 | **) 25 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t160-closure.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | let f () = ();; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 BRANCH 14 11 | 11 CONST0 12 | 12 RETURN 1 13 | 14 CLOSURE 0, 11 14 | 17 PUSHACC0 15 | 18 MAKEBLOCK1 0 16 | 20 POP 1 17 | 22 SETGLOBAL T160-closure 18 | 24 STOP 19 | **) 20 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t162-return.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | let f _ = 0 in f 0;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 BRANCH 14 11 | 11 CONST0 12 | 12 RETURN 1 13 | 14 CLOSURE 0, 11 14 | 17 PUSHCONST0 15 | 18 PUSHACC1 16 | 19 APPLY1 17 | 20 POP 1 18 | 22 ATOM0 19 | 23 SETGLOBAL T162-return 20 | 25 STOP 21 | **) 22 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t163.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | let f _ _ = 0 in f 0;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 BRANCH 17 11 | 11 RESTART 12 | 12 GRAB 1 13 | 14 CONST0 14 | 15 RETURN 2 15 | 17 CLOSURE 0, 12 16 | 20 PUSHCONST0 17 | 21 PUSHACC1 18 | 22 APPLY1 19 | 23 POP 1 20 | 25 ATOM0 21 | 26 SETGLOBAL T163 22 | 28 STOP 23 | **) 24 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t190-makefloatblock-1.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | let x = 0.0 in [| x |];; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 GETGLOBAL 0 11 | 11 PUSHACC0 12 | 12 MAKEFLOATBLOCK 1 13 | 14 POP 1 14 | 16 ATOM0 15 | 17 SETGLOBAL T190-makefloatblock-1 16 | 19 STOP 17 | **) 18 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t190-makefloatblock-2.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | let x = 0.0 in [| x; x |];; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 GETGLOBAL 0 11 | 11 PUSHACC0 12 | 12 PUSHACC1 13 | 13 MAKEFLOATBLOCK 2 14 | 15 POP 1 15 | 17 ATOM0 16 | 18 SETGLOBAL T190-makefloatblock-2 17 | 20 STOP 18 | **) 19 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t190-makefloatblock-3.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | let x = 0.0 in [| x; x; x |];; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 GETGLOBAL 0 11 | 11 PUSHACC0 12 | 12 PUSHACC1 13 | 13 PUSHACC2 14 | 14 MAKEFLOATBLOCK 3 15 | 16 POP 1 16 | 18 ATOM0 17 | 19 SETGLOBAL T190-makefloatblock-3 18 | 21 STOP 19 | **) 20 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t250-closurerec-1.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | let rec f _ = 0;; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 BRANCH 14 11 | 11 CONST0 12 | 12 RETURN 1 13 | 14 CLOSUREREC 0, 11 14 | 18 ACC0 15 | 19 MAKEBLOCK1 0 16 | 21 POP 1 17 | 23 SETGLOBAL T250-closurerec-1 18 | 25 STOP 19 | **) 20 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocaml/t330-compact-1.ml: -------------------------------------------------------------------------------- 1 | open Lib;; 2 | Gc.compact ();; 3 | 4 | (** 5 | 0 CONSTINT 42 6 | 2 PUSHACC0 7 | 3 MAKEBLOCK1 0 8 | 5 POP 1 9 | 7 SETGLOBAL Lib 10 | 9 CONST0 11 | 10 C_CALL1 gc_compaction 12 | 12 ATOM0 13 | 13 SETGLOBAL T330-compact-1 14 | 15 STOP 15 | **) 16 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocamldoc/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . < int -> string -> (string * string * string) -> 16 | (string * string * string) -> 17 | (string * string * string) -> unit 18 | val y : int 19 | end 20 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocamldoc/t02.ml: -------------------------------------------------------------------------------- 1 | module Foo = struct type u type t = int let x = 1 end;; 2 | module type TFoo = module type of Foo;; 3 | 4 | module type TBar = TFoo with type u := float;; 5 | 6 | module type Gee = 7 | sig 8 | module M : module type of Foo 9 | include module type of Foo 10 | end 11 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocamldoc/t02.reference: -------------------------------------------------------------------------------- 1 | # 2 | # module T02: 3 | # 4 | # module T02.Foo: 5 | # 6 | # module type T02.TFoo: 7 | # 8 | # module type T02.TBar: 9 | # 10 | # module type T02.Gee: 11 | # 12 | # module T02.Gee.M: 13 | -------------------------------------------------------------------------------- /testsuite/tests/tool-ocamldoc/t03.ml: -------------------------------------------------------------------------------- 1 | module Foo = struct type t = int let x = 1 end;; 2 | module type MT = module type of Foo;; 3 | module Bar = struct type t = int let x = 2 end;; 4 | 5 | module type MT2 = sig type t val x : t end;; 6 | module type Gee = MT2 with type t = float ;; 7 | module T = (val (if true then (module Foo:MT2 with type t = int) else (module Bar: MT2 with type t = int)) : MT2 with type t = int);; -------------------------------------------------------------------------------- /testsuite/tests/tool-ocamldoc/t03.reference: -------------------------------------------------------------------------------- 1 | # 2 | # module T03: 3 | # 4 | # module T03.Foo: 5 | # 6 | # module type T03.MT: 7 | # 8 | # module T03.Bar: 9 | # 10 | # module type T03.MT2: 11 | # 12 | # module type T03.Gee: 13 | # 14 | # module T03.T: 15 | -------------------------------------------------------------------------------- /testsuite/tests/typing-fstclassmod/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . < expr 9 | end;; 10 | 11 | class app e1 e2 : exp = 12 | object 13 | val l = e1 14 | val r = e2 15 | method eval env = 16 | match l with 17 | | `Abs(var,body) -> 18 | Hashtbl.add env var r; 19 | body 20 | | _ -> `App(l,r); 21 | end 22 | -------------------------------------------------------------------------------- /testsuite/tests/typing-objects-bugs/pr4435_bad.ml: -------------------------------------------------------------------------------- 1 | (* Two v's in the same class *) 2 | class c v = object initializer print_endline v val v = 42 end;; 3 | new c "42";; 4 | 5 | (* Two hidden v's in the same class! *) 6 | class c (v : int) = 7 | object 8 | method v0 = v 9 | inherit ((fun v -> object method v : string = v end) "42") 10 | end;; 11 | (new c 42)#v0;; 12 | -------------------------------------------------------------------------------- /testsuite/tests/typing-objects-bugs/pr4766_ok.ml: -------------------------------------------------------------------------------- 1 | class virtual ['a] c = 2 | object (s : 'a) 3 | method virtual m : 'b 4 | end 5 | 6 | let o = 7 | object (s :'a) 8 | inherit ['a] c 9 | method m = 42 10 | end 11 | -------------------------------------------------------------------------------- /testsuite/tests/typing-objects-bugs/pr4824_ok.ml: -------------------------------------------------------------------------------- 1 | module M : 2 | sig 3 | class x : int -> object method m : int end 4 | end 5 | = 6 | struct 7 | class x _ = object 8 | method m = 42 9 | end 10 | end;; 11 | -------------------------------------------------------------------------------- /testsuite/tests/typing-objects-bugs/pr4824a_bad.ml: -------------------------------------------------------------------------------- 1 | module M : sig class c : 'a -> object val x : 'b end end = 2 | struct class c x = object val x = x end end 3 | 4 | class c (x : int) = object inherit M.c x method x : bool = x end 5 | 6 | let r = (new c 2)#x;; 7 | -------------------------------------------------------------------------------- /testsuite/tests/typing-objects-bugs/pr5156_ok.ml: -------------------------------------------------------------------------------- 1 | class type t = object end;; 2 | class ['a] o1 = object (self : #t as 'a) end;; 3 | type 'a obj = ( < .. > as 'a);; 4 | class type ['a] o2 = object ('a obj) end;; 5 | class ['a] o3 = object (self : 'a obj) end;; 6 | class ['a] o4 = object (self) method m = (self : 'a obj) end;; 7 | (* 8 | let o = object (self : 'a obj) end;; 9 | let o = object (self) method m = (self : 'a obj) end;; 10 | *) 11 | -------------------------------------------------------------------------------- /testsuite/tests/typing-objects-bugs/woodyatt_ok.ml: -------------------------------------------------------------------------------- 1 | (* test.ml *) 2 | class alfa = object(_:'self) 3 | method x: 'a. ('a, out_channel, unit) format -> 'a = Printf.printf 4 | end 5 | 6 | class bravo a = object 7 | val y = (a :> alfa) 8 | initializer y#x "bravo initialized" 9 | end 10 | 11 | class charlie a = object 12 | inherit bravo a 13 | initializer y#x "charlie initialized" 14 | end 15 | -------------------------------------------------------------------------------- /testsuite/tests/typing-objects/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . < passed") || echo " => failed" 4 | 5 | clean: defaultclean 6 | 7 | include ../../makefiles/Makefile.common 8 | -------------------------------------------------------------------------------- /testsuite/tests/typing-polyvariants-bugs-2/pr3918a.mli: -------------------------------------------------------------------------------- 1 | type 'a voption = [ `None | `Some of 'a] 2 | -------------------------------------------------------------------------------- /testsuite/tests/typing-polyvariants-bugs-2/pr3918b.mli: -------------------------------------------------------------------------------- 1 | type 'a vlist = ('a * 'b) Pr3918a.voption as 'b 2 | -------------------------------------------------------------------------------- /testsuite/tests/typing-polyvariants-bugs-2/pr3918c.ml: -------------------------------------------------------------------------------- 1 | (* 2 | ocamlc -c pr3918a.mli pr3918b.mli 3 | rm -f pr3918a.cmi 4 | ocamlc -c pr3918c.ml 5 | *) 6 | 7 | open Pr3918b 8 | 9 | let f x = (x : 'a vlist :> 'b vlist) 10 | let f (x : 'a vlist) = (x : 'b vlist) 11 | -------------------------------------------------------------------------------- /testsuite/tests/typing-polyvariants-bugs/Makefile: -------------------------------------------------------------------------------- 1 | include ../../makefiles/Makefile.okbad 2 | include ../../makefiles/Makefile.common 3 | -------------------------------------------------------------------------------- /testsuite/tests/typing-polyvariants-bugs/pr4775_ok.ml: -------------------------------------------------------------------------------- 1 | module type Poly = sig 2 | type 'a t = 'a constraint 'a = [> ] 3 | end 4 | 5 | module Combine (A : Poly) (B : Poly) = struct 6 | type ('a, 'b) t = 'a A.t constraint 'a = 'b B.t 7 | end 8 | 9 | module C = Combine 10 | (struct type 'a t = 'a constraint 'a = [> ] end) 11 | (struct type 'a t = 'a constraint 'a = [> ] end) 12 | -------------------------------------------------------------------------------- /testsuite/tests/typing-polyvariants-bugs/pr4933_ok.ml: -------------------------------------------------------------------------------- 1 | module type Priv = sig 2 | type t = private int 3 | end 4 | 5 | module Make (Unit:sig end): Priv = struct type t = int end 6 | 7 | module A = Make (struct end) 8 | 9 | module type Priv' = sig 10 | type t = private [> `A] 11 | end 12 | 13 | module Make' (Unit:sig end): Priv' = struct type t = [`A] end 14 | 15 | module A' = Make' (struct end) 16 | -------------------------------------------------------------------------------- /testsuite/tests/typing-polyvariants-bugs/pr5057_ok.ml: -------------------------------------------------------------------------------- 1 | (* PR5057 *) 2 | 3 | module TT = struct 4 | module IntSet = Set.Make(struct type t = int let compare = compare end) 5 | end 6 | 7 | let () = 8 | let f flag = 9 | let module T = TT in 10 | let _ = match flag with `A -> 0 | `B r -> r in 11 | let _ = match flag with `A -> T.IntSet.mem | `B r -> r in 12 | () 13 | in 14 | f `A 15 | -------------------------------------------------------------------------------- /testsuite/tests/typing-polyvariants-bugs/pr5057a_bad.ml: -------------------------------------------------------------------------------- 1 | (* This one should fail *) 2 | 3 | let f flag = 4 | let module T = Set.Make(struct type t = int let compare = compare end) in 5 | let _ = match flag with `A -> 0 | `B r -> r in 6 | let _ = match flag with `A -> T.mem | `B r -> r in 7 | () 8 | -------------------------------------------------------------------------------- /testsuite/tests/typing-private-bugs/Makefile: -------------------------------------------------------------------------------- 1 | include ../../makefiles/Makefile.okbad 2 | include ../../makefiles/Makefile.common 3 | -------------------------------------------------------------------------------- /testsuite/tests/typing-private-bugs/pr5026_bad.ml: -------------------------------------------------------------------------------- 1 | type untyped;; 2 | type -'a typed = private untyped;; 3 | type -'typing wrapped = private sexp 4 | and +'a t = 'a typed wrapped 5 | and sexp = private untyped wrapped;; 6 | class type ['a] s3 = object 7 | val underlying : 'a t 8 | end;; 9 | class ['a] s3object r : ['a] s3 = object 10 | val underlying = r 11 | end;; 12 | -------------------------------------------------------------------------------- /testsuite/tests/typing-private/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . < int) *) 2 | module rec A : sig type t = B.t -> int end = struct type t = B.t -> int end 3 | and B : sig type t = A.t end = struct type t = A.t end;; 4 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t06ok.ml: -------------------------------------------------------------------------------- 1 | (* OK (t = ) *) 2 | module rec A : sig type t = end = struct type t = end 3 | and B : sig type t = A.t end = struct type t = A.t end;; 4 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t07bad.ml: -------------------------------------------------------------------------------- 1 | (* Bad (not regular) *) 2 | module rec A : sig type 'a t = end 3 | = struct type 'a t = end;; 4 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t08bad.ml: -------------------------------------------------------------------------------- 1 | (* Bad (not regular) *) 2 | module rec A : sig type 'a t = end 3 | = struct type 'a t = end 4 | and B : sig type 'a t = 'a A.t end = struct type 'a t = 'a A.t end;; 5 | 6 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t09bad.ml: -------------------------------------------------------------------------------- 1 | (* Bad (not regular) *) 2 | module rec A : sig type 'a t = 'a B.t end 3 | = struct type 'a t = 'a B.t end 4 | and B : sig type 'a t = end 5 | = struct type 'a t = end;; 6 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t10ok.ml: -------------------------------------------------------------------------------- 1 | (* OK *) 2 | module rec A : sig type 'a t = 'a array B.t * 'a list B.t end 3 | = struct type 'a t = 'a array B.t * 'a list B.t end 4 | and B : sig type 'a t = end 5 | = struct type 'a t = end;; 6 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t11bad.ml: -------------------------------------------------------------------------------- 1 | (* Bad (not regular) *) 2 | module rec A : sig type 'a t = 'a list B.t end 3 | = struct type 'a t = 'a list B.t end 4 | and B : sig type 'a t = end 5 | = struct type 'a t = end;; 6 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t12bad.ml: -------------------------------------------------------------------------------- 1 | (* Bad (not regular) *) 2 | module rec M : 3 | sig 4 | class ['a] c : 'a -> object 5 | method map : ('a -> 'b) -> 'b M.c 6 | end 7 | end 8 | = struct 9 | class ['a] c (x : 'a) = object 10 | method map : 'b. ('a -> 'b) -> 'b M.c 11 | = fun f -> new M.c (f x) 12 | end 13 | end;; 14 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t13ok.ml: -------------------------------------------------------------------------------- 1 | (* OK *) 2 | class type [ 'node ] extension = object method node : 'node end 3 | class type [ 'ext ] node = object constraint 'ext = 'ext node #extension end 4 | class x = object method node : x node = assert false end 5 | type t = x node;; 6 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t14bad.ml: -------------------------------------------------------------------------------- 1 | (* Bad - PR 4261 *) 2 | 3 | module PR_4261 = struct 4 | module type S = 5 | sig 6 | type t 7 | end 8 | 9 | module type T = 10 | sig 11 | module D : S 12 | type t = D.t 13 | end 14 | 15 | module rec U : T with module D = U' = U 16 | and U' : S with type t = U'.t = U 17 | end;; 18 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t15bad.ml: -------------------------------------------------------------------------------- 1 | (* Bad - PR 4512 *) 2 | module type S' = sig type t = int end 3 | module rec M : S' with type t = M.t = struct type t = M.t end;; 4 | -------------------------------------------------------------------------------- /testsuite/tests/typing-recmod/t19ok.ml: -------------------------------------------------------------------------------- 1 | (* PR 4758, PR 4266 *) 2 | 3 | module PR_4758 = struct 4 | module type S = sig end 5 | module type Mod = sig 6 | module Other : S 7 | end 8 | module rec A : S = struct 9 | end and C : sig include Mod with module Other = A end = struct 10 | module Other = A 11 | end 12 | end 13 | 14 | -------------------------------------------------------------------------------- /testsuite/tests/typing-typeparam/.svnignore: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | svn propset svn:ignore -F - . < `basename $$file ml`result; \ 8 | diff -q `basename $$file ml`reference `basename $$file ml`result > /dev/null && echo " => passed" || echo " => failed"; \ 9 | done; 10 | 11 | clean: defaultclean 12 | @rm -f *.result $(EXECNAME) 13 | 14 | include ../../makefiles/Makefile.common 15 | -------------------------------------------------------------------------------- /testsuite/tests/warnings/w01.ml: -------------------------------------------------------------------------------- 1 | 2 | (* C *) 3 | 4 | let foo = ( *);; 5 | 6 | 7 | (* F *) 8 | 9 | let f x y = x;; 10 | f 1; f 1;; 11 | 12 | 13 | (* M *) 14 | 15 | (* duh *) 16 | 17 | 18 | (* P *) 19 | 20 | let 1 = 1;; 21 | 22 | 23 | (* S *) 24 | 25 | 1; 1;; 26 | 27 | 28 | (* U *) 29 | 30 | match 1 with 31 | | 1 -> () 32 | | 1 -> () 33 | | _ -> () 34 | ;; 35 | 36 | 37 | (* V *) 38 | 39 | (* re-duh *) 40 | 41 | 42 | (* X *) 43 | 44 | (* re-re *) 45 | -------------------------------------------------------------------------------- /tools/.cvsignore: -------------------------------------------------------------------------------- 1 | ocamldep 2 | ocamldep.opt 3 | ocamldep.bak 4 | ocamlprof 5 | opnames.ml 6 | dumpobj 7 | dumpapprox 8 | objinfo 9 | cvt_emit 10 | cvt_emit.bak 11 | cvt_emit.ml 12 | ocamlcp 13 | ocamlmktop 14 | primreq 15 | ocamldumpobj 16 | keywords 17 | lexer299.ml 18 | ocaml299to3 19 | ocamlmklib 20 | ocamlmklib.ml 21 | lexer301.ml 22 | scrapelabels 23 | addlabels 24 | myocamlbuild_config.ml 25 | objinfo_helper 26 | -------------------------------------------------------------------------------- /tools/Characters: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/tools/Characters -------------------------------------------------------------------------------- /tools/DoMake: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/tools/DoMake -------------------------------------------------------------------------------- /tools/MakeDepend: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/tools/MakeDepend -------------------------------------------------------------------------------- /tools/OCamlc-custom: -------------------------------------------------------------------------------- 1 | # OCamlc with option -custom 2 | # Macintosh version 3 | 4 | set echo 0 5 | set -e ocamlcommands "{tempfolder}"OCaml.temp."`date -n`" 6 | echo >"{ocamlcommands}" 7 | ocamlc -custom {"parameters"} 8 | execute "{ocamlcommands}" 9 | 10 | delete -y "{ocamlcommands}" 11 | -------------------------------------------------------------------------------- /tools/Time: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/tools/Time -------------------------------------------------------------------------------- /tools/cleanup-header: -------------------------------------------------------------------------------- 1 | #!/bin/sed -f 2 | # Remove private parts from runtime include files, before installation 3 | # in /usr/local/lib/ocaml/caml 4 | 5 | /\/\* \*\// { 6 | r ../config/m.h 7 | d 8 | } 9 | /\/\* \*\// { 10 | r ../config/s.h 11 | d 12 | } 13 | /\/\* \*\//,/\/\* <\/private> \*\//d 14 | -------------------------------------------------------------------------------- /tools/make-opcodes: -------------------------------------------------------------------------------- 1 | $1=="enum" {n=0; next; } 2 | {for (i = 1; i <= NF; i++) {printf("let op%s = %d\n", $i, n++);}} 3 | -------------------------------------------------------------------------------- /utils/.cvsignore: -------------------------------------------------------------------------------- 1 | config.ml 2 | -------------------------------------------------------------------------------- /win32caml/ocaml.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/win32caml/ocaml.ico -------------------------------------------------------------------------------- /win32caml/ocaml.rc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/colinbenner/ocaml-llvm/8cf9c9991ce8e5c4e700d286355eba45cd86b9c0/win32caml/ocaml.rc -------------------------------------------------------------------------------- /win32caml/resource.h: -------------------------------------------------------------------------------- 1 | //{{NO_DEPENDENCIES}} 2 | // Microsoft Visual C++ generated include file. 3 | // Used by ocaml.rc 4 | // 5 | 6 | // Next default values for new objects 7 | // 8 | #ifdef APSTUDIO_INVOKED 9 | #ifndef APSTUDIO_READONLY_SYMBOLS 10 | #define _APS_NO_MFC 1 11 | #define _APS_NEXT_RESOURCE_VALUE 101 12 | #define _APS_NEXT_COMMAND_VALUE 40001 13 | #define _APS_NEXT_CONTROL_VALUE 1000 14 | #define _APS_NEXT_SYMED_VALUE 101 15 | #endif 16 | #endif 17 | -------------------------------------------------------------------------------- /yacc/.cvsignore: -------------------------------------------------------------------------------- 1 | ocamlyacc 2 | *.c.x 3 | ocamlyacc.xcoff 4 | version.h 5 | .gdb_history 6 | --------------------------------------------------------------------------------