Skip to content

Use MathJax format for complexity annotations #830

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

Merged
merged 3 commits into from
May 3, 2022
Merged
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
2 changes: 1 addition & 1 deletion containers-tests/benchmarks/LookupGE/LookupGE_IntMap.hs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ lookupGE4 k t = k `seq` case t of
-- Utilities
-------------------------------------------------------------------------------

-- | /O(log n)/. The minimal key of the map.
-- | \(O(\log n)\). The minimal key of the map.
findMinMaybe :: IntMap a -> Maybe (Key, a)
findMinMaybe m
| null m = Nothing
Expand Down
4 changes: 2 additions & 2 deletions containers/src/Data/IntMap.hs
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,9 @@
--
-- Operation comments contain the operation time complexity in
-- the Big-O notation <http://en.wikipedia.org/wiki/Big_O_notation>.
-- Many operations have a worst-case complexity of /O(min(n,W))/.
-- Many operations have a worst-case complexity of \(O(\min(n,W))\).
-- This means that the operation can become linear in the number of
-- elements with a maximum of /W/ -- the number of bits in an 'Int'
-- elements with a maximum of \(W\) -- the number of bits in an 'Int'
-- (32 or 64).
-----------------------------------------------------------------------------

Expand Down
220 changes: 110 additions & 110 deletions containers/src/Data/IntMap/Internal.hs

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions containers/src/Data/IntMap/Lazy.hs
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
--
-- == Detailed performance information
--
-- The amortized running time is given for each operation, with /n/ referring to
-- the number of entries in the map and /W/ referring to the number of bits in
-- The amortized running time is given for each operation, with \(n\) referring to
-- the number of entries in the map and \(W\) referring to the number of bits in
-- an 'Int' (32 or 64).
--
-- Benchmarks comparing "Data.IntMap.Lazy" with other dictionary
Expand Down
4 changes: 2 additions & 2 deletions containers/src/Data/IntMap/Strict.hs
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@
--
-- == Detailed performance information
--
-- The amortized running time is given for each operation, with /n/ referring to
-- the number of entries in the map and /W/ referring to the number of bits in
-- The amortized running time is given for each operation, with \(n\) referring to
-- the number of entries in the map and \(W\) referring to the number of bits in
-- an 'Int' (32 or 64).
--
-- Benchmarks comparing "Data.IntMap.Strict" with other dictionary
Expand Down
96 changes: 48 additions & 48 deletions containers/src/Data/IntMap/Strict/Internal.hs

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions containers/src/Data/IntSet.hs
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@
--
-- == Performance information
--
-- Many operations have a worst-case complexity of /O(min(n,W))/.
-- Many operations have a worst-case complexity of \(O(\min(n,W))\).
-- This means that the operation can become linear in the number of
-- elements with a maximum of /W/ -- the number of bits in an 'Int'
-- elements with a maximum of \(W\) -- the number of bits in an 'Int'
-- (32 or 64).
--
--
Expand Down
Loading