Skip to content

Instantly share code, notes, and snippets.

trait AbstractResource[T] {
val version: String
type Foo
implicit def self: this.type = this
}
object MyResource extends AbstractResource[MyResource] {
override final val version = "v3"
override type Foo = Int
}
./Data/Aeson/TH.hs:549:1: Warning: Eta reduce
Found:
(<^>) a b = infixApp a [| (E.><) |] b
Why not:
(<^>) a = infixApp a [| (E.><) |]
./Data/Aeson/TH.hs:1632:40: Suggestion: Use infix
Found:
union droppedKindVarNames kvNames'
Why not:
adam.bergmark ~/r/3/r/reedsolomon-0.0.4.1 /master $ stack haddock -v
Version 1.2.0 x86_64 hpack-0.14.0
2016-09-25 13:29:57.814359: [debug] Checking for project config at: /Users/adam.bergmark/repos/3rd/reedsolomon-0.0.4.1/reedsolomon-0.0.4.1/stack.yaml
@(Stack/Config.hs:792:9)
2016-09-25 13:29:57.815524: [debug] Loading project config file stack.yaml
@(Stack/Config.hs:810:13)
2016-09-25 13:29:57.817141: [debug] Trying to decode /Users/adam.bergmark/.stack/build-plan-cache/x86_64-osx/lts-7.0.cache
@(Data/Store/VersionTagged.hs:68:5)
2016-09-25 13:29:57.826950: [debug] Success decoding /Users/adam.bergmark/.stack/build-plan-cache/x86_64-osx/lts-7.0.cache
@(Data/Store/VersionTagged.hs:72:13)
@bergmark
bergmark / gist:14aa76448fd7e4ea4f4b676a9ba54856
Created June 7, 2016 09:17
rethinkdb-client-driver build log
V~> ghc --version
The Glorious Glasgow Haskell Compilation System, version 7.10.3
V~> cd repos/trustee/
V~/r/trustee> mkdir rethinkdb-client-driver
V~/r/trustee> cd rethinkdb-client-driver/
V~/r/t/rethinkdb-client-driver> cabal sandbox init
Writing a default package environment file to
/Users/adam/repos/trustee/rethinkdb-client-driver/cabal.sandbox.config
Creating a new sandbox at
/Users/adam/repos/trustee/rethinkdb-client-driver/.cabal-sandbox
@bergmark
bergmark / curator.txt
Last active March 11, 2016 11:03
stackage & GHC 8 @ 2016-03-11
HUnit-1.3.1.1 is out of bounds for:
- [ ] deepseq-1.4.1.2 (==1.2.*). No maintainer. @haskell
QuickCheck-2.8.2 is out of bounds for:
- [ ] bytestring-0.10.6.0 (>=2.4 && < 2.7). No maintainer. @haskell
binary-0.8.2.1 is out of bounds for:
- [ ] Cabal-ide-backend-1.23.0.0 (==0.7.*). No maintainer. @haskell
- [ ] Network-NineP-0.4.0 (>=0.5.1.0 && < 0.8). Sergey Alirzaev <[email protected]>. @l29ah
- [ ] approximate-0.2.2.3 (>=0.5 && < 0.8). Edward Kmett <[email protected]>. @ekmett
MonadCatchIO-transformers (not present) depended on by:
- [ ] hdocs-0.4.4.0 (>=0.3.0). Alexandr Ruchkin [email protected] @mvoidex. @mvoidex
- [ ] heist-0.14.1.1 (>=0.2.1 && < 0.4). No maintainer. @mightybyte
- [ ] http-streams-0.8.3.3 (-any). Andrew Cowie <[email protected]> @afcowie. @afcowie
- [ ] snap-0.14.0.6 (>=0.2 && < 0.4). No maintainer. @mightybyte
- [ ] snap-core-0.9.8.0 (>=0.2.1 && < 0.4). No maintainer. @mightybyte
- [ ] snap-server-0.9.5.1 (>=0.2.1 && < 0.4). No maintainer. @mightybyte
HUnit-1.3.0.0 depended on by:
- deepseq-1.4.1.2 (==1.2.*). No maintainer. @haskell
QuickCheck-2.8.1 depended on by:
- bytestring-0.10.6.0 (>=2.4 && < 2.7). No maintainer. @haskell
binary-0.8.0.0 depended on by:
- Agda-2.4.2.5 (>=0.7.2.1 && < 0.8). Andrés Sicard-Ramírez <[email protected]> @asr. @agda
- Cabal-ide-backend-1.23.0.0 (==0.7.*). No maintainer. @haskell
- JuicyPixels-3.2.6.4 (>=0.5 && < 0.8). Vincent Berthoux <[email protected]>. @Twinside
example/Example.hs:1:1: Splicing declarations
mkId ''Id
======>
example/Example.hs:25:1-9
unsafeId :: UUID -> Id
unsafeId = Id
unsafeId' :: UUID -> Maybe Id
unsafeId' = (.) Just Id
instance FromField Id where
fromField = fromFieldAux unsafeId'
#!/bin/bash
cabal configure && cabal build && cabal haddock --hyperlink-source --html-location='http://localhost:8080/package/$pkg/docs' --contents-location='http://localhost:8080/package/$pkg'
S=$?
if [ "${S}" -eq "0" ]; then
cd "dist/doc/html"
DDIR="${1}-${2}-docs"
cp -r "${1}" "${DDIR}" && tar -c -v -z --format=ustar -f "${DDIR}.tar.gz" "${DDIR}"
CS=$?
if [ "${CS}" -eq "0" ]; then
echo "Uploading to Hackage…"
// x :: Either (Either a b) c -> Either a (Either b c)
// x = either (either Left (Right . Left)) (Right . Right)
interface Either<A,B> {
left? : A;
right? : B;
}
class Fns
{