~ubuntu-branches/debian/sid/ocaml/sid

« back to all changes in this revision

Viewing changes to debugger/primitives.mli

  • Committer: Bazaar Package Importer
  • Author(s): Stephane Glondu
  • Date: 2009-06-24 12:47:31 UTC
  • mfrom: (1.1.9 upstream)
  • Revision ID: james.westby@ubuntu.com-20090624124731-7wao0d0mnk4d71ee
Remove build-dependency to docbook-* (not needed anymore, since
policy has been moved to dh-ocaml)

Show diffs side-by-side

added added

removed removed

Lines of Context:
11
11
(*                                                                     *)
12
12
(***********************************************************************)
13
13
 
14
 
(* $Id: primitives.mli,v 1.2 1999/11/17 18:57:26 xleroy Exp $ *)
 
14
(* $Id: primitives.mli,v 1.2.40.1 2009/04/02 09:44:21 xclerc Exp $ *)
15
15
 
16
16
(********************* Basic functions and types ***********************)
17
17
 
29
29
(* Position of an element in a list. Head of list has position 0. *)
30
30
val index : 'a -> 'a list -> int
31
31
 
32
 
(* Remove on element from an association list. *)
33
 
val assoc_remove : ('a * 'b) list -> 'a -> ('a * 'b) list
34
 
 
35
 
(* Nth element of a list. *)
36
 
val list_nth : 'a list -> int -> 'a
37
 
 
38
32
(* Return the `n' first elements of `l'. *)
39
33
(* ### n l -> l' *)
40
34
val list_truncate : int -> 'a list -> 'a list
47
41
(* ### x y l -> l' *)
48
42
val list_replace : 'a -> 'a -> 'a list -> 'a list
49
43
 
50
 
(* Filter `list' according to `predicate'. *)
51
 
(* ### predicate list -> list' *)
52
 
val filter : ('a -> bool) -> 'a list -> 'a list
53
 
 
54
 
(* Find the first element `element' of `list' *)
55
 
(* so that `predicate element' holds. *)
56
 
(* Raise `Not_found' if no such element. *)
57
 
(* ### predicate list -> element *)
58
 
val find : ('a -> bool) -> 'a list -> 'a
59
 
 
60
44
(*** Operations on strings. ***)
61
45
 
62
 
(* Return the position of the first occurence of char `c' in string `s' *)
63
 
(* Raise `Not_found' if `s' does not contain `c'. *)
64
 
(* ### c s -> pos *)
65
 
val string_pos : string -> char -> int
66
 
 
67
46
(* Remove blanks (spaces and tabs) at beginning and end of a string. *)
68
47
val string_trim : string -> string
69
48