Commit Graph

19 Commits (master)

Author SHA1 Message Date
Nicolás Ojeda Bär a0cef9fdc6 Rename Bad_docstring => Unexpected_docstring 2020-07-20 08:31:18 +02:00
Leo White a534650f41 Add locations to docstring attributes 2020-04-17 09:21:31 +01:00
Drup abc53d1a6e Annotate constant literals with the location of their content. 2019-11-13 16:08:40 +01:00
Hugo Heuzard 0814a7261f The parser keeps previous location when relocating ast node 2018-09-06 16:12:00 +01:00
Nicolás Ojeda Bär 07ed67112f Use $loc and $sloc (requires Menhir >= 20180703)
This commit includes a menhir parser bootstrap, as it changes the
Docstrings API and thus wouldn't work for the previous bootstrapped
parser.
2018-09-01 23:17:04 +02:00
Gabriel Scherer 573e66806c provide a menhir-friendly interface to Docstrings 2018-09-01 23:17:03 +02:00
Hugo Heuzard 8043144494 Add locations to attributes
Changes

fix typo
2018-08-06 13:19:28 +01:00
Leo White 08df330392 Don't drop doc comments in empty signatures 2018-04-03 16:59:12 +01:00
Fourchaux 72cfdd56e9 Typos and basic grammar error fixing (#1280) 2017-08-10 11:59:23 +01:00
Hugo Heuzard 3d72f214e1 Parser: delay registration of docstring after the mapper is applied 2016-07-11 07:40:57 +02:00
octachron eb5ab7aa2b Empty documentation comment (**)
This commit adds (**) as a special empty documentation comment that
can influence the attachment of other documentation comments but is
never emitted as an attribute in the parsetree. An important use of
this empty comment would be to attach a documentation comment to the
type t and not its last constructor Label, without spurious empty
attribute, in the following construction:

type t = Label (**)
(**doc for t*)
2016-06-09 19:59:50 +02:00
Damien Doligez 520fb2df50 Merge tag 4.03.0 into trunk. 2016-04-28 16:13:21 +02: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
alainfrisch 87de6a160d Useless bindings, unit patterns, whitespace. 2016-01-19 23:40:55 +01:00
Drup 6095df954e Rename parsetree constants.
PConst -> Pconst
int -> integer
2016-01-18 00:12:38 +01:00
Hugo Heuzard 9eca3e4519 Parse arbitrary precision integers ..
.. and allow any letter in [g-zG-Z] as modifier (previously 'l','L','n')
Also allow modifier for floats
This give more freedom to ppx rewritters (what about a ppx for zarith)

Checks are performed when translating from Parsetree to Typedtree.
Invalid_literal is raised if the modifier is not recognized ([lLn]?)
Integer_overflow is raised as before.

Lexer: use g-zG-Z for integer literal modifier

Lexer: Allow modifier on float

Clean wrt previous commits

Lexer: use named substring

Cleanup

typo

doc

fix after rebase

rebase on  trunk

Update typecore.ml

Fix printast.ml
2015-12-03 17:20:48 +01:00
Damien Doligez b860d63145 whitespace cleanup, cut long lines, add some missing headers
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16415 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-09-11 11:58:31 +00:00
Leo White 5c55e4cc08 Attach documentation comments to Parsetree
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@16189 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
2015-06-28 13:11:50 +00:00