Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

the new quoted string literal syntax is not documented #6597

Closed
vicuna opened this issue Oct 4, 2014 · 5 comments

Comments

Projects
None yet
1 participant
@vicuna
Copy link

commented Oct 4, 2014

Original bug ID: 6597
Reporter: @gasche
Status: resolved (set by @xavierleroy on 2017-02-06T19:00:59Z)
Resolution: fixed
Priority: normal
Severity: minor
Version: 4.02.0
Target version: 4.03.1+dev
Fixed in version: 4.05.0 +dev/beta1/beta2/beta3/rc1
Category: documentation
Tags: junior_job

Bug description

http://caml.inria.fr/pub/docs/manual-ocaml/lex.html

does not mention the new string literal syntax {foo|...|foo}

@vicuna

This comment has been minimized.

Copy link
Author

commented Oct 6, 2014

Comment author: @alainfrisch

It is listed in language extensions:

http://caml.inria.fr/pub/docs/manual-ocaml/extn.html#sec244

@vicuna

This comment has been minimized.

Copy link
Author

commented Oct 6, 2014

Comment author: @gasche

Indeed! I should have looked there. I sent my report after an email from Jean-Christophe Filliâtre (politely) complaining that this was undocumented.

To my knowledge this is the only language extension that affects the lexical specification of the language, and not only the grammar. One could argue that having a full view of the lexical conventions (I understand all the ways OCaml code can be lexed) is more important than having a full view of the grammar. I would be in favor of having an explicit mention of the new syntax in the "standard" part of the manual, that would point to the extension description for more details. Would you agree?

@vicuna

This comment has been minimized.

Copy link
Author

commented Oct 6, 2014

Comment author: @damiendoligez

To my knowledge this is the only language extension that affects the lexical specification of the language, and not only the grammar.

Not true: integer literals for types int32, int64 and nativeint are in the same boat.

On the other hand, the fact that "assert", "lazy", "private", ":=", ".." are keywords is recorded in the "lexical conventions" chapter, while they are only used in extensions.

What I would like to see is a "see also" footnote (or something equivalent) on each nonterminal (lexical or syntactic) that is modified by a language extension.

@vicuna

This comment has been minimized.

Copy link
Author

commented Feb 5, 2017

Comment author: @Octachron

See #1030 for an implementation of the "footnote or equivalent" idea.

@vicuna

This comment has been minimized.

Copy link
Author

commented Feb 6, 2017

Comment author: @xavierleroy

Fixed by merge of #1030.

@vicuna vicuna closed this Feb 6, 2017

@vicuna vicuna added this to the 4.03.1 milestone Mar 14, 2019

@vicuna vicuna added the bug label Mar 20, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.