Xavier Leroy
bb83542732
Reflecting commit 14976 on version/4.02:
...
PR#6211: in toplevel interactive use, bad interaction between uncaught
exceptions and multiple bindings of the form "let x = a let y = b;;".
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14977 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-06-09 15:14:41 +00:00
Mark Shinwell
60d0af57c4
merge from 4.02: rev. 14858, Adding #ppx toplevel directive (patch by Peter Zotov, github #54 ).
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14928 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-30 12:10:06 +00:00
Jacques Garrigue
77cf8b999e
* split Typetexp.lookup_module and Typetexp.find_module
...
* fix semantics of -open by using Typemod.type_open_
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14795 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-12 12:02:26 +00:00
Jacques Garrigue
ccce272966
commit o_and_opens.diff
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14787 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-11 00:17:05 +00:00
Mark Shinwell
a9cc0281e5
cycle detection in the toplevel printer (Leo White, https://github.com/ocaml/ocaml/pull/23/ )
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14766 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-08 08:31:45 +00:00
Jacques Garrigue
1ce29d9bfc
re-commit Leo's weak-dependencies pull request
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14755 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-07 00:34:20 +00:00
Jacques Garrigue
fc24112e25
change -trans-mod to -no-alias-deps, and update message
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14738 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-05 02:05:30 +00:00
Jacques Garrigue
b56dc4b3df
PR#5584: merge open extensible types, extension-patch-4.0.2
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14737 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-04 23:08:45 +00:00
Jacques Garrigue
95104b3924
revert commit 14719
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14723 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-02 06:19:55 +00:00
Mark Shinwell
521ac0213a
weak dependencies with -trans-mod (github/ocamllabs/weak-depends 45e980a,21856a7,merge)
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14719 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-05-01 12:50:20 +00:00
Damien Doligez
5b8df637d2
merge branch "safe-string"
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14705 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-29 11:56:17 +00:00
Alain Frisch
d2de0d7b18
Revert 14616, 14617. Go back to the original syntax for toplevel directives, only allowing capitalized identifiers in addition to lowercase ones. Split #show into variants #show_val, #show_type, etc, and implement a generic #show which combines all the results.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14697 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-28 08:04:43 +00:00
Alain Frisch
3775a101e6
Avoid bad error report when a registered toplevel primitive raises Not_found.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14671 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-23 16:18:22 +00:00
Alain Frisch
ec52baed6f
#5377 : add a #show directive to the toplevel.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14618 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-17 09:24:14 +00:00
Alain Frisch
26a8bc20a7
Support for toplevel primitives with multiple arguments.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14616 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-16 16:51:37 +00:00
Jacques Garrigue
3b4d7cf63b
Merge module-alias branch (cf. PR#6063)
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14394 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-01-10 07:53:33 +00:00
Jacques Garrigue
d90b126bd4
Add -trans-mod option for transparent module dependencies.
...
Without that option, dependencies are strict, both for
typing and linking.
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14382 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-12-20 06:55:26 +00:00
Alain Frisch
0f6f367ad4
Change the representation of exception slots: instead of being represented as 'string ref', they are now blocks
...
of size 2, with tag = Object_tag, the first field being the pointer to the string, and second one being a unique id, generated
from the same sequence as for object values. Special case for predefined exceptions, represented with a negative id.
The unique id generator is moved from camlinternalOO to the C runtime system.
Also fix some bugs.
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14239 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-23 14:28:31 +00:00
Alain Frisch
d802a51be6
#6203 : change representation of exception values created with a constant constructor: the value is now equal to the exception slot. This avoids some allocation when the constructor is called and an extra indirection on matching against the constructor.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/raise_variants@14235 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-18 13:00:58 +00:00
Jacques Garrigue
7a904bb8db
make path normalization safer; now Core not only compiles but works
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/module-alias@14212 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-10-04 02:06:40 +00:00
Alain Frisch
cc31694f7c
Keep attributes on module declarations.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14195 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-09-27 17:05:39 +00:00
Alain Frisch
645dcf25e5
Keep location and attributes in type, label and constructor declarations. Deprecated warning when a deprecated type or constructor is referenced.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14191 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-09-27 10:54:55 +00:00
Alain Frisch
b92a3ca792
Continue.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/exception_registration@14122 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-09-12 15:50:47 +00:00
Alain Frisch
884ca00fdf
Continue cleanup. driver/errors.ml is no longer needed.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/exception_registration@14120 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-09-12 14:45:03 +00:00
Damien Doligez
7844495624
Merge branch 4.01 from branching point to 4.01.0+rc1
...
Command line used:
svn merge --accept postpone -r 13776:14055 $REPO/version/4.01 .
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14060 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-09-04 15:12:37 +00:00
Alain Frisch
842f6794a9
Synchronize with trunk.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/extension_points@14042 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-08-28 17:10:04 +00:00
Gabriel Scherer
b1c5fa3e52
PR#6071: Add a -noinit option to the toplevel [patch by David Sheets]
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13972 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-08-04 19:58:09 +00:00
Alain Frisch
b0d5fc28a2
Synchronize with trunk.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/extension_points@13922 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-07-22 17:03:39 +00:00
Fabrice Le Fessant
1823936ce0
Fix OCAMLPARAM problems
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13901 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-07-17 12:35:26 +00:00
Alain Frisch
525ef9d703
Synchronize with trunk.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/extension_points@13897 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-07-16 13:34:30 +00:00
Fabrice Le Fessant
aa53c7c59d
Fix ocamlnat compilation
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13770 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-06-12 13:33:43 +00:00
Fabrice Le Fessant
ad6c285818
Improved implementation of OCAMLPARAM
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13747 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-06-05 16:34:40 +00:00
Jacques Garrigue
f35c7d123f
Take ambiguity into account when using -short-paths option.
...
Namely, do not use an abbreviated form which doesn't correspond
directly to a physical definition when it might point to
several definitions, due to multiple opens.
Also be careful about not abbreviating types we are defining
in type definitions.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13635 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-04-30 09:05:26 +00:00
Alain Frisch
04de43bee5
Attributes on Pstr_eval.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/extension_points@13512 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-04-11 14:07:32 +00:00
Alain Frisch
b0987fd693
Attributes on expresions (etc) are now stored in the expression record, to facilitate pattern matching on structured fragments of AST while ignoring attributes. Introducing a new Ast_helper module to help creating AST fragments.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/extension_points@13381 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-03-08 14:59:45 +00:00
Alain Frisch
d32b19008a
Parse recursive module as standard modules, and check in the type-checker that an explicit type is provided. (Unfinished.)
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/extension_points@13353 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-03-05 16:50:05 +00:00
Jacques Garrigue
26e1ff7138
Merge short-paths into a fresh branch of trunk.
...
Also fix a bit unification and subtyping errors.
You now need the flag -short-path to activate short paths.
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/short-paths-4.01@13285 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-01-29 14:21:12 +00:00
Alain Frisch
ef9fc7ab0f
#5904 : support for -ppx in the toplevel.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13278 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2013-01-25 09:12:31 +00:00
Alain Frisch
f1d0e5afab
Add a -dtypedtree flag to all tools (using Printtyped). Also fix ocamlnat.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13139 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-12-18 17:19:53 +00:00
Wojciech Meyer
bda692b6da
PR#5825: Add a primitive to use source file wrapped in the coresponding module.
...
Patch by Grégoire Henry!
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13097 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-11-18 16:16:50 +00:00
Alain Frisch
0b37b27356
Stop keeping a Path.t to refer to labels and constructors in the Typedtree AST. This is not used internally and it is not a robust way to identify these objects unambiguously anyway
...
(especially when we will add more powerful disambiguation strategies). The correct way to identify an item is through the pair (type,name), which can be deduced from the
label_description/constructor_description stored in the Typedtree.
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13043 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-10-24 12:03:00 +00:00
Alain Frisch
dfa500533a
#5741 : make Pprintast available from the command-line (-dsource).
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13025 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-10-17 16:09:38 +00:00
Damien Doligez
59371b9d75
remove TABs
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13014 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-10-15 18:01:26 +00:00
Damien Doligez
def31744f9
remove all $Id keywords
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13013 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-10-15 17:50:56 +00:00
Alain Frisch
08c3b1780a
PR#5787: Bad behavior of 'Unused ...' warnings in the toplevel.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13010 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-10-12 08:24:34 +00:00
Jacques Garrigue
35185d610b
merge version/4.00 at revision 12866
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/short-paths@12869 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-08-21 07:10:35 +00:00
Jacques Garrigue
d165ca651e
PR#5722: toplevel: print full module path only for first record field
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@12861 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-08-14 05:23:40 +00:00
Damien Doligez
997a678d5e
clean up TABs and whitespace
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@12799 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-07-30 18:04:46 +00:00
Damien Doligez
1330131d70
PR#5677: do not use "value" as identifier (genprintval.ml)
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@12690 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-07-10 15:03:11 +00:00
Gabriel Scherer
b667a00686
PR#5628: Add Topdirs.remove_directory (and directive #remove_directory) to remove a directory from the load path
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@12660 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2012-07-07 11:40:33 +00:00