Commit 8376f7f5 authored by Mikhail Glushenkov's avatar Mikhail Glushenkov
Browse files

s/1.26/2.0/

[ci skip]
parent 2c2b558a
......@@ -208,7 +208,7 @@ enabledBenchLBIs pkg lbi =
-- | Get a list of all enabled 'Component's (both buildable and
-- requested by the user at configure-time).
--
-- @since 1.26.0.0
-- @since 2.0.0.0
enabledComponents :: PackageDescription -> LocalBuildInfo
-> [Component]
enabledComponents pkg lbi =
......
......@@ -41,7 +41,7 @@ componentBuildInfo =
-- See also this note in
-- "Distribution.Types.ComponentEnabledSpec#buildable_vs_enabled_components".
--
-- @since 1.26.0.0
-- @since 2.0.0.0
--
componentBuildable :: Component -> Bool
componentBuildable = buildable . componentBuildInfo
......
......@@ -50,7 +50,7 @@ import Data.Maybe (isNothing)
-- See also this note in
-- "Distribution.Types.ComponentEnabledSpec#buildable_vs_enabled_components".
--
-- @since 1.26.0.0
-- @since 2.0.0.0
data ComponentEnabledSpec
= ComponentEnabledSpec {
testsEnabled :: Bool,
......@@ -62,27 +62,27 @@ instance Binary ComponentEnabledSpec
-- | The default set of enabled components. Historically tests and
-- benchmarks are NOT enabled by default.
--
-- @since 1.26.0.0
-- @since 2.0.0.0
defaultComponentEnabled :: ComponentEnabledSpec
defaultComponentEnabled = ComponentEnabledSpec False False
-- | Is this component enabled? See also this note in
-- "Distribution.Types.ComponentEnabledSpec#buildable_vs_enabled_components".
--
-- @since 1.26.0.0
-- @since 2.0.0.0
componentEnabled :: ComponentEnabledSpec -> Component -> Bool
componentEnabled enabled = isNothing . componentDisabledReason enabled
-- | Is this component name enabled? See also this note in
-- "Distribution.Types.ComponentEnabledSpec#buildable_vs_enabled_components".
--
-- @since 1.26.0.0
-- @since 2.0.0.0
componentNameEnabled :: ComponentEnabledSpec -> ComponentName -> Bool
componentNameEnabled enabled = isNothing . componentNameDisabledReason enabled
-- | Is this component disabled, and if so, why?
--
-- @since 1.26.0.0
-- @since 2.0.0.0
componentDisabledReason :: ComponentEnabledSpec -> Component
-> Maybe ComponentDisabledReason
componentDisabledReason enabled comp
......@@ -90,7 +90,7 @@ componentDisabledReason enabled comp
-- | Is this component name disabled, and if so, why?
--
-- @since 1.26.0.0
-- @since 2.0.0.0
componentNameDisabledReason :: ComponentEnabledSpec -> ComponentName
-> Maybe ComponentDisabledReason
componentNameDisabledReason enabled (CTestName _)
......@@ -101,7 +101,7 @@ componentNameDisabledReason _ _ = Nothing
-- | A reason explaining why a component is disabled.
--
-- @since 1.26.0.0
-- @since 2.0.0.0
data ComponentDisabledReason = DisabledComponent
| DisabledAllTests
| DisabledAllBenchmarks
......@@ -358,7 +358,7 @@ pkgComponents pkg =
-- indicate if we are actually going to build the component,
-- see 'enabledComponents' instead.
--
-- @since 1.26.0.0
-- @since 2.0.0.0
--
pkgBuildableComponents :: PackageDescription -> [Component]
pkgBuildableComponents = filter componentBuildable . pkgComponents
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment