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

Fatal error parsing format strings #2785

Closed
vicuna opened this issue Jun 19, 2004 · 2 comments
Closed

Fatal error parsing format strings #2785

vicuna opened this issue Jun 19, 2004 · 2 comments
Labels

Comments

@vicuna
Copy link

vicuna commented Jun 19, 2004

Original bug ID: 2785
Reporter: administrator
Status: closed
Resolution: fixed
Priority: normal
Severity: minor
Category: ~DO NOT USE (was: OCaml general)

Bug description

Hi,

please try the following code:

Printf.printf "%f, %L)"

Running "ocaml" on it (latest CVS-version) will throw an exception:

Fatal error: exception Invalid_argument("String.sub")

Regards,
Markus

--
Markus Mottl http://www.oefai.at/~markus markus@oefai.at

@vicuna
Copy link
Author

vicuna commented Jun 21, 2004

Comment author: administrator

Hi Markus,

please try the following code:

Printf.printf "%f, %L)"

Running "ocaml" on it (latest CVS-version) will throw an exception:

Fatal error: exception Invalid_argument("String.sub")

Regards,
Markus

--
Markus Mottl http://www.oefai.at/~markus markus@oefai.at

Thank you for the bug report.

It was a stupid error, one that cannot be caught by the compiler:

I wrote j - i in place of j - 1

Hard to see, if the font is not properly chosen!

It is corrected in the release branch.

Pierre Weis

INRIA, Projet Cristal, Pierre.Weis@inria.fr, http://pauillac.inria.fr/~weis/

@vicuna
Copy link
Author

vicuna commented Jun 22, 2004

Comment author: administrator

Bug introduced by PW 2004-06-14, fixed by PW 2004-06-21

@vicuna vicuna closed this as completed Jun 22, 2004
@vicuna vicuna added the bug label Mar 19, 2019
dra27 pushed a commit to dra27/ocaml that referenced this issue Feb 27, 2021
git-svn-id: http://caml.inria.fr/svn/ocaml/version/3.08@6435 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant