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

Conformité code source et doc #8293

Closed
vicuna opened this issue Sep 22, 2003 · 2 comments
Closed

Conformité code source et doc #8293

vicuna opened this issue Sep 22, 2003 · 2 comments
Labels

Comments

@vicuna
Copy link

vicuna commented Sep 22, 2003

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

Bug description

Full_Name: Valérie Ménissier-Morain
Version: 3-07beta2
OS: Linux/RedHat 7.2
Submission from: realarith.lip6.fr (132.227.66.34)

La fonction Str.group_beginning est documentée comme levant l'exception
Not_found:

val group_beginning : int -> int

group_beginning n returns the position of the first character of the
substring that was matched by the nth group of the regular expression.
Raises Not_found if the nth group of the regular expression was not matched.

Au cours d'une exécution, je vois apparaître le message suivant:

Fatal error: exception Invalid_argument("Str.group_beginning")

alors que je rattrape effectivement l'exception Not_found.

Est-ce un bug, un défaut de documentation ou bien ai-je compris quelque chose de
travers?

Valérie.
P.S.: si on peut éviter d'avoir besoin du code et de l'environnement
d'exécution, vue la taille, ce serait bien!

@vicuna
Copy link
Author

vicuna commented Sep 23, 2003

Comment author: administrator

La fonction Str.group_beginning est documente comme levant l'exception
Not_found:
[...]
Au cours d'une excution, je vois apparatre le message suivant:

Fatal error: exception Invalid_argument("Str.group_beginning")

D'apres une rapide lecture du source, Invalid_argument signifie que
l'expression reguliere n'avait pas de n-ieme groupe, alors que
Not_found signifie que le n-ieme groupe n'a pas matche.
Je change la doc.

Merci pour le rapport de bug,

-- Damien

@vicuna
Copy link
Author

vicuna commented Sep 23, 2003

Comment author: administrator

fixed DD 2003-09-23
cf #8294

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