Skip to content

Commit

Permalink
be more private about our modules
Browse files Browse the repository at this point in the history
  • Loading branch information
PragTob committed May 21, 2018
1 parent e02fd12 commit e885f6b
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 24 deletions.
8 changes: 4 additions & 4 deletions lib/benchee/benchmark/measure.ex
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
defmodule Benchee.Benchmark.Measure do
@moduledoc """
A thing that measures something about a function execution - like time or
memory needed.
"""
@moduledoc false

# A thing that measures something about a function execution - like time or
# memory needed.

@doc """
Takes an anonymous 0 arity function to measure and returns the measurement
Expand Down
8 changes: 4 additions & 4 deletions lib/benchee/benchmark/measure/memory.ex
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
defmodule Benchee.Benchmark.Measure.Memory do
@moduledoc """
Measure memory consumption of a function.
@moduledoc false

Returns `{nil, return_value}` in case the memory measurement went bad.
"""
# Measure memory consumption of a function.
#
# Returns `{nil, return_value}` in case the memory measurement went bad.

@behaviour Benchee.Benchmark.Measure

Expand Down
10 changes: 5 additions & 5 deletions lib/benchee/benchmark/measure/native_time.ex
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
defmodule Benchee.Benchmark.Measure.NativeTime do
@moduledoc """
Measure the time elapsed while executing a given function.
@moduledoc false

Uses only the time unit native to the platform. Used for determining how many times a function
should be repeated in `Benchee.Benchmark.Runner.determine_n_times/3` (private method though).
"""
# Measure the time elapsed while executing a given function.
#
# Uses only the time unit native to the platform. Used for determining how many times a function
# should be repeated in `Benchee.Benchmark.Runner.determine_n_times/3` (private method though).

@behaviour Benchee.Benchmark.Measure

Expand Down
16 changes: 8 additions & 8 deletions lib/benchee/benchmark/measure/time.ex
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
defmodule Benchee.Benchmark.Measure.Time do
@moduledoc """
Measure the time elapsed while executing a given function.
@moduledoc false

In contrast to `:timer.tc/1` it always returns the result in nano seconds instead of micro
seconds. This helps us avoid losing precision as both Linux and MacOSX seem to be able to
measure in nano seconds. `:timer.tc/n`
[forfeits this precision](
https://github.com/erlang/otp/blob/master/lib/stdlib/src/timer.erl#L164-L169).
"""
# Measure the time elapsed while executing a given function.
#
# In contrast to `:timer.tc/1` it always returns the result in nano seconds instead of micro
# seconds. This helps us avoid losing precision as both Linux and MacOSX seem to be able to
# measure in nano seconds. `:timer.tc/n`
# [forfeits this precision](
# https://github.com/erlang/otp/blob/master/lib/stdlib/src/timer.erl#L164-L169).

@behaviour Benchee.Benchmark.Measure

Expand Down
1 change: 1 addition & 0 deletions lib/benchee/benchmark/repeated_measurement.ex
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
defmodule Benchee.Benchmark.RepeatedMeasurement do
@moduledoc false

# This module is an internal implementation detail, and should absolutely not be relied upon
# from external clients.
#
Expand Down
7 changes: 4 additions & 3 deletions lib/benchee/benchmark/scenario_context.ex
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
defmodule Benchee.Benchmark.ScenarioContext do
@moduledoc """
This struct holds the context in which any scenario is run.
"""
@moduledoc false

# This struct holds the context in which any scenario is run.

defstruct [
:config,
:printer,
Expand Down

0 comments on commit e885f6b

Please sign in to comment.