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

doc bug for Str.search_backward; typo for search_forward #2370

Closed
vicuna opened this issue Mar 23, 2004 · 1 comment
Closed

doc bug for Str.search_backward; typo for search_forward #2370

vicuna opened this issue Mar 23, 2004 · 1 comment
Labels

Comments

@vicuna
Copy link

vicuna commented Mar 23, 2004

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

Bug description

Salut,

The documentation for Str.search_backward in 3.07pl2 is unclear. See:
http://caml/ocaml/htmlman/libref/Str.html. In particular, it doesn't
mention that the returned substring can overhang the position
argument.

I suggest the following rewording:

[[search_backward r s last]] searches the string [[s]] for a
substring matching the regular expression [[r]]. The search first
considers substrings that start at position [[last]] and proceeds
towards the beginning of string. Return the position of the first
character of the matched substring, or [[raise Not_found]] if no
substring matches.

Also, there's a typo in the search_forward doc just above: searchs'' |-> searches''.

Amicalement,
James

@vicuna
Copy link
Author

vicuna commented Apr 13, 2004

Comment author: administrator

fixed DD 2004-04-13

@vicuna vicuna closed this as completed Apr 13, 2004
@vicuna vicuna added the bug label Mar 19, 2019
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