Leo White
bc8c0d2538
Make the `mark` parameters in `Includemod` non-optional
2020-06-25 11:35:00 +01:00
Thomas Refis
e4de6c19b1
use uid for usage warnings
2020-03-05 13:35:12 +01:00
Leo White
ecfaffe9de
Short circuit simple inclusion checks
2020-03-04 15:20:32 +00:00
Gabriel Scherer
6465616fd9
improved error messages for exceptions in signature errors
...
Example:
module Test : sig
exception Foo
end = struct
end
Before this PR:
Modules do not match: sig end is not included in sig exception Foo end
The extension constructor `Foo' is required but not provided
After this PR (second line changed):
Modules do not match: sig end is not included in sig exception Foo end
The exception `Foo' is required but not provided
2019-11-12 14:16:39 +01:00
Thomas Refis
8e928caea7
a better representation for modules with no name ( #8908 )
2019-10-09 14:15:37 +01:00
Leo White
c19e8b2350
Refactor environment lookup functions
2019-08-15 15:56:50 +01:00
Florian Angeletti
04a9c8be61
Rename printing function in Printtyp.Conflicts
2019-07-31 13:52:59 +02:00
Mekhrubon Turaev
6cb5905c27
Improved type hierarchy for type mismatches ( #8828 )
...
Added special types for variants, records, constructors or labels type mismatch.
Printing additional info about types mismatch during compilation error.
2019-07-30 08:56:28 +01:00
Jacques Garrigue
4fe08b25d6
Fix #7851 by checking type declaration coherence for recursive modules ( #8570 )
2019-04-19 10:57:55 +09:00
Thomas Refis
8138da1963
includemod: never modify scope of signatures
2019-04-16 10:56:05 +01:00
Florian Angeletti
8e5e3c0ed4
Improved error message for illegal permutations ( #8546 )
...
* illegal permutation: more explanations and tests
2019-03-27 19:04:24 +01:00
Runhang Li
97329f30ed
Extend `open` to arbritrary module expressions in structures and to
...
applicative module paths in signatures
2018-11-26 16:20:37 +00:00
Alain Frisch
4c130cae87
Fix wrong calls to Env.normalize_path on non-module paths ( #2131 )
2018-11-22 16:07:15 +01:00
Leo White
111d4e1827
Remove positions from paths
2018-11-21 03:39:34 -05:00
Alain Frisch
2e5b9d1ef1
"Alerts" as a generalization of "deprecated" ( #1804 )
2018-11-15 09:51:35 +01:00
Jérémie Dimino
9124ab82d1
Deprecate Pervasives ( #1605 )
...
- inline Pervasives in Stdlib and re-add Pervasives as a deprecated
module that aliases all elements of Stdlib except the stdlib modules.
- remove special case for Stdlib.Pervasives in printtyp.ml
2018-08-27 12:42:14 +01:00
Thomas Refis
c00a46e2cf
more precise extension mismatch error messages
2018-08-09 10:18:54 +01:00
Gabriel Radanne
1be47bf7ab
Just some tbl things. ( #1699 )
2018-07-23 13:19:41 +01:00
Florian Angeletti
349db3d869
PR#6416 et al.: injective mapping between identifiers and printed names ( #1120 )
2018-06-26 22:03:45 +02:00
Jacques Garrigue
3d33bd4ef5
Fix MPR#7751 ( #1657 )
...
Fix the toplevel printer, to have it properly load needed cmi's.
2018-03-27 09:25:28 +09:00
Leo White
bce9d4b659
Fix usage warnings with no mli file ( #1358 )
2018-03-14 17:57:31 +01:00
Valentin Gatien-Baron
c5722f1e4d
share code that checks that the functor application F(M) is well-typed
2017-12-12 23:51:19 -05:00
alainfrisch
6071c8f640
Remove blank line to improve readability.
2017-05-15 16:20:18 +02:00
alainfrisch
fa9e40496e
Class declarations create a class type declaration in signature: no need to check twice.
2017-05-09 14:15:54 +02:00
alainfrisch
e7e7afd280
Support for modules and module types.
2017-05-09 14:01:04 +02:00
alainfrisch
dd2ced22d9
Support for deprecated class/class types.
2017-05-09 13:47:49 +02:00
alainfrisch
5f0e745159
Support for deprecated_mutable attribute.
2017-05-09 13:35:41 +02:00
alainfrisch
04f4f4a745
Support for deprecated attribute on constructors.
2017-05-09 13:17:41 +02:00
alainfrisch
18ca259774
Move logic from Includemod to Includecore.
2017-05-09 12:57:07 +02:00
alainfrisch
f6d53cc38f
Deprecation warning when checking signature inclusion
...
Deprecation warning (3) is currently only reported when directly
accessing a component marked with the deprecated attribute; but it is
missed when we coerce the signature contaning the deprecated component
to a signature without the attribute.
This commit adds the required machinery to detect such cases
and report the same warning. (An alternative design could be
to introduce a new warning for that purpose.)
Some of the new machinery could be used for other purposes:
- During the inclusion check, keep the location that would used in
the error message if the check fails.
- Warnings can now hold extra "sub-locations" (and associated
messages).
2017-04-05 19:13:59 +02:00
alainfrisch
5cd405b077
Use Btype.is_row_name instead of an inlined version of it.
2017-02-20 11:09:18 +01:00
Leo White
55a21ff051
Add label to bool parameter
2016-07-28 10:13:32 +01:00
Leo White
caadb9de8a
Allow more module aliases in strengthening
2016-07-28 10:13:32 +01:00
alainfrisch
32f0e2120c
Detect unused module declarations.
2016-07-18 10:35:19 +02:00
Jacques Garrigue
2913cf11b0
Fix PR#7112
2016-03-16 18:23:46 +01:00
alainfrisch
502e4f9336
More warnings when compiling the compiler.
2016-03-15 22:46:35 +01:00
Damien Doligez
5401ce8473
Update headers for the new license.
...
Remains to be done: remove all headers in testsuite/tests.
2016-02-18 16:59:16 +01:00
Alain Frisch
a033839139
#6688 : allow val declarations as structure items.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15645 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-12-10 13:37:50 +00:00
Gabriel Scherer
7bacc5beb4
Typedtree: add type information to primitive coercions
...
This will enable type-directed optimizations during translation of
module coercions.
WARNING: this breaks Typedtree representation, magic number will have to
be adjusted.
From: Frederic Bour <frederic.bour@lakaban.net>
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15582 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-11-17 11:55:24 +00:00
Damien Doligez
031cffd155
merge branch 4.02 from release 4.02.0 to release 4.02.1
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15558 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-10-15 13:34:58 +00:00
Jacques Garrigue
e757455115
Fix PR#6465: allow incremental weakening of module aliases
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15405 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-10-01 09:07:14 +00:00
Alain Frisch
378a967cb7
Sync with trunk.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/constructors_with_record3@15190 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-09-04 16:11:12 +00:00
Damien Doligez
cbfe627f92
merge changes from branch 4.02 from branching (rev 14852) to 4.02.0+rc1 (rev 15121)
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@15125 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-08-22 13:45:02 +00:00
Alain Frisch
50f47df33a
Sync with trunk. Rebinding of inlined extension constructors with free variables is not yet supported.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/constructors_with_record3@15069 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-08-07 16:07:55 +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
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
eb617b5fe7
Synchronize with trunk.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/constructors_with_record3@14657 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-22 14:33:41 +00:00
Jacques Garrigue
82e2f35a14
Fix PR#6376
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14650 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-21 10:38:04 +00:00
Alain Frisch
6346154d4b
Synchronize with trunk.
...
git-svn-id: http://caml.inria.fr/svn/ocaml/branches/constructors_with_record3@14587 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-14 11:52:29 +00:00
Damien Doligez
7303ac34ca
fix some of the whitespace problems in the source
...
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@14582 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2014-04-12 10:17:02 +00:00