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

Invalid_argument("index out of bounds") from ocamldoc on trunk #6767

Closed
vicuna opened this Issue Jan 30, 2015 · 1 comment

Comments

Projects
None yet
2 participants
@vicuna
Copy link
Collaborator

commented Jan 30, 2015

Original bug ID: 6767
Reporter: @alainfrisch
Assigned to: @alainfrisch
Status: closed (set by @xavierleroy on 2016-12-07T10:47:19Z)
Resolution: fixed
Priority: normal
Severity: minor
Fixed in version: 4.03.0+dev / +beta1
Category: ocamldoc
Monitored by: @gasche @hcarty

Bug description

After synchronizing with trunk, I get the following error from ocamldoc:

Fatal error: exception Invalid_argument("index out of bounds")
Raised by primitive operation at file "odoc_html.ml", line 72, characters 16-28
Called from file "odoc_html.ml", line 91, characters 27-49
Called from file "odoc_html.ml", line 2310, characters 48-58
Called from file "list.ml", line 91, characters 12-15
Called from file "list.ml", line 91, characters 12-15
Called from file "odoc_html.ml", line 2332, characters 8-32
Called from file "odoc_html.ml", line 2792, characters 8-46
Called from file "odoc.ml", line 126, characters 6-32

The argument 'name' in the Odoc_html.html_files function is equal to "Pervasives." (with the final dot character, hence the exception).

In the f_ele function (around line 2310), we have:

name e = "Pervasives..()"
Name.simple (name e) = "()"
Name.father (name e) = "Pervasives."

So this seems to be related to the new support for custom index operators.

@vicuna

This comment has been minimized.

Copy link
Collaborator Author

commented Jan 30, 2015

Comment author: @alainfrisch

Hopefully fixed by commit 15801.

Seriously, the function Odoc_name.cut is really an example of code obfuscation and should be rewritten.

@vicuna vicuna closed this Dec 7, 2016

@vicuna vicuna added the ocamldoc label 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.