Skip to content

Commit

Permalink
Merge pull request #293 from serokell/gromak/maintenance-jan24
Browse files Browse the repository at this point in the history
[Chore] Update some dependencies, cleanup
  • Loading branch information
gromakovsky authored Mar 15, 2024
2 parents 38668fb + 6b8b1c4 commit 89788bf
Show file tree
Hide file tree
Showing 10 changed files with 59 additions and 42 deletions.
23 changes: 14 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,31 +31,36 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest, macOS-latest, windows-latest]
cabal: ["3.8"]
cabal: ["3.10"]
# If you update this list of supported compiler versions,
# make sure to update the `tested-with` section of `universum.cabal`.
ghc:
- "8.8.4"
- "8.10.7"
- "9.0.2"
- "9.2.8"
- "9.4.5"
# Use only the latest compiler on non-Linux
- "9.6.3"
- "9.8.1"
# Use only the "main" (usually latest) compiler version on non-Linux
exclude:
- os: macOS-latest
ghc: 9.8.1
- os: macOS-latest
ghc: 9.4.5
- os: macOS-latest
ghc: 9.2.8
- os: macOS-latest
ghc: 9.0.2
- os: macOS-latest
ghc: 8.8.4
- os: macOS-latest
ghc: 8.10.7
- os: windows-latest
ghc: 9.8.1
- os: windows-latest
ghc: 9.4.5
- os: windows-latest
ghc: 9.2.8
- os: windows-latest
ghc: 9.0.2
- os: windows-latest
ghc: 8.8.4
- os: windows-latest
ghc: 8.10.7

Expand Down Expand Up @@ -95,8 +100,8 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
stack: ["2.9.3"]
ghc: ["9.4.5"]
stack: ["2.13.1"]
ghc: ["9.6.3"]

steps:
- uses: actions/checkout@v4
Expand Down
7 changes: 7 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
1.8.2.1
=======

* [#293](https://github.com/serokell/universum/pull/293)
* Add explicit kind signatures for custom operators.
* Bump some dependency constraints to support GHC-9.8.

1.8.2
=====

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ Universum

[![GitHub CI](https://github.com/serokell/universum/workflows/CI/badge.svg)](https://github.com/serokell/universum/actions)
[![Hackage](https://img.shields.io/hackage/v/universum.svg)](https://hackage.haskell.org/package/universum)
<!-- TODO [#288]: enable these once -->
<!-- [![Stackage LTS](http://stackage.org/package/universum/badge/lts)](http://stackage.org/lts/package/universum) -->
[![Stackage LTS](http://stackage.org/package/universum/badge/lts)](http://stackage.org/lts/package/universum)
<!-- TODO [#288]: re-enable once the package is back to nightly -->
<!-- [![Stackage Nightly](http://stackage.org/package/universum/badge/nightly)](http://stackage.org/nightly/package/universum) -->
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

Expand Down
2 changes: 1 addition & 1 deletion src/Universum/Debug.hs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
{-# LANGUAGE CPP #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DerivingStrategies #-}
Expand All @@ -8,7 +9,6 @@
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE RankNTypes #-}
{-# LANGUAGE Trustworthy #-}
{-# LANGUAGE TypeInType #-}

-- | Functions for debugging. If you left these functions in your code
-- then warning is generated to remind you about left usages. Also, some
Expand Down
2 changes: 1 addition & 1 deletion src/Universum/String/Conversion.hs
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ are still the expected ones (see the comments there for what to expect).
* You may optionally check whether any changes to `pack` and `unpack` functions
and their `INLINE`/`NOINLINE` annotations took place.
The current rewrite rules match with what happens in `text` package
at the e5644b663c32c01a1de7299a5e711216755e01bc commit, and next time
at the c826a6cb3d29242ce3632b490670ae7997689eaa commit, and next time
you can just check `git diff <that commit>..HEAD`.
If these points hold, it should be safe to raise the upper bound on `text` version.
Expand Down
21 changes: 12 additions & 9 deletions src/Universum/TypeOps.hs
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE ExplicitNamespaces #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE Safe #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# LANGUAGE ConstraintKinds #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE ExplicitNamespaces #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE PolyKinds #-}
{-# LANGUAGE Safe #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE StandaloneKindSignatures #-}
{-# LANGUAGE TypeOperators #-}

-- | Type operators for writing convenient type signatures.

Expand All @@ -25,6 +26,7 @@ import Data.Kind (Constraint)
-- =
-- f :: Either String (Maybe Int)
-- @
type ($) :: (k2 -> k1) -> k2 -> k1
type f $ a = f a
infixr 2 $

Expand Down Expand Up @@ -66,4 +68,5 @@ type family Each (c :: [k -> Constraint]) (as :: [k]) where
-- =
-- a :: (Show a, Read a) => a -> a
-- @
type With :: [k -> Constraint] -> k -> Constraint
type With a b = a <+> b
2 changes: 1 addition & 1 deletion stack.yaml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
resolver: lts-21.0
resolver: lts-22.4
8 changes: 4 additions & 4 deletions stack.yaml.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
packages: []
snapshots:
- completed:
sha256: 1867d84255dff8c87373f5dd03e5a5cb1c10a99587e26c8793e750c54e83ffdc
size: 639139
url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/21/0.yaml
original: lts-21.0
sha256: 8b211c5a6aad3787e023dfddaf7de7868968e4f240ecedf14ad1c5b2199046ca
size: 714097
url: https://raw.githubusercontent.com/commercialhaskell/stackage-snapshots/master/lts/22/4.yaml
original: lts-22.4
5 changes: 5 additions & 0 deletions test/Test/Universum/StringProps.hs
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
-- Some tests in this module have a caveat: they depend on compiler
-- optimizations and will likely fail if compiled with -O0.
-- That's because they depend on rewrite rules (and test these rules),
-- and these rules are usually not triggered without certain optimizations.

module Test.Universum.StringProps
( hprop_StringToTextAndBack
, hprop_StringToTextAndBackSurrogate
Expand Down
27 changes: 12 additions & 15 deletions universum.cabal
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
cabal-version: 2.2
name: universum
version: 1.8.2
version: 1.8.2.1
synopsis: Custom prelude used in Serokell
description: See README.md file for more details.
homepage: https://github.com/serokell/universum
Expand All @@ -13,11 +13,12 @@ category: Prelude
stability: stable
build-type: Simple
bug-reports: https://github.com/serokell/universum/issues
tested-with: GHC == 8.8.4
, GHC == 8.10.7
tested-with: GHC == 8.10.7
, GHC == 9.0.2
, GHC == 9.2.8
, GHC == 9.4.5
, GHC == 9.6.3
, GHC == 9.8.1
extra-doc-files: CHANGES.md
, CONTRIBUTING.md
, README.md
Expand All @@ -40,8 +41,7 @@ common common-options
-Wno-missing-local-signatures
-Wno-monomorphism-restriction
-Wno-implicit-prelude
if impl(ghc >= 8.10.1)
ghc-options: -Wno-prepositive-qualified-module
-Wno-prepositive-qualified-module
-Wno-inferred-safe-imports
if impl(ghc >= 9.2.0)
ghc-options: -Wno-missing-kind-signatures
Expand Down Expand Up @@ -107,7 +107,7 @@ library
, stm
-- Make sure that "toString-toText-rewritting" note
-- is still valid when bumping this constraint.
, text >= 1.0.0.0 && <= 2.0.2
, text >= 1.0.0.0 && <= 2.1.1
, transformers
, unordered-containers
, utf8-string
Expand Down Expand Up @@ -140,9 +140,7 @@ test-suite universum-test
build-tool-depends:
tasty-discover:tasty-discover

if impl(ghc >= 8.10.1)
ghc-options: -Wno-missing-safe-haskell-mode

ghc-options: -Wno-missing-safe-haskell-mode
ghc-options: -threaded

test-suite universum-doctest
Expand All @@ -157,15 +155,13 @@ test-suite universum-doctest
build-depends: doctest
, Glob

if impl(ghc >= 8.10.1)
ghc-options: -Wno-missing-safe-haskell-mode
ghc-options: -Wno-missing-safe-haskell-mode
ghc-options: -threaded
-- https://github.com/sol/doctest/issues/327
-- TODO: re-enable when the issue is resolved
if impl(ghc >= 9.0.0)
buildable: False

ghc-options: -threaded

benchmark universum-benchmark
import: common-options
type: exitcode-stdio-1.0
Expand All @@ -179,8 +175,9 @@ benchmark universum-benchmark
, text
, unordered-containers

if impl(ghc >= 8.10.1)
ghc-options: -Wno-missing-safe-haskell-mode
ghc-options: -Wno-missing-safe-haskell-mode
if impl(ghc >= 9.8.0)
ghc-options: -Wno-x-partial

default-extensions: NoImplicitPrelude
ScopedTypeVariables

0 comments on commit 89788bf

Please sign in to comment.