Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions internals/measurement_sample.ml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ type t =
; mutable promoted : int
; mutable major_collections : int
; mutable minor_collections : int
; mutable extra : float String.Map.t
; mutable extra : (string * float) list
}
[@@deriving sexp, fields ~getters ~iterators:fold]

Expand All @@ -24,7 +24,7 @@ let create () =
; promoted = 0
; major_collections = 0
; minor_collections = 0
; extra = String.Map.empty
; extra = []
}
;;

Expand Down Expand Up @@ -63,7 +63,7 @@ let field_values_to_string t =
~promoted:prepend_int
~extra:(fun xs extra ->
let extra = Field.get extra t in
assert (Map.is_empty extra);
assert (List.is_empty extra);
xs)
|> List.rev
|> String.concat ~sep:","
Expand Down Expand Up @@ -125,5 +125,5 @@ let accessor = function
| `Major_allocated -> floatify_int major_allocated
| `Promoted -> floatify_int promoted
| `One -> fun _ -> 1.
| `Extra str -> fun t -> Map.find_exn t.extra str
| `Extra str -> fun t -> List.Assoc.find_exn t.extra ~equal:String.equal str
;;
2 changes: 1 addition & 1 deletion internals/measurement_sample.mli
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ type t =
; mutable promoted : int
; mutable major_collections : int
; mutable minor_collections : int
; mutable extra : float String.Map.t
; mutable extra : (string * float) list
}
[@@deriving sexp]

Expand Down