mirror of
https://github.com/ilyakooo0/ormolu.git
synced 2024-10-27 11:41:17 +03:00
Output multiple specialize pragmas in a row nicer
We should not insert newlines between them.
This commit is contained in:
parent
e98df37597
commit
656d0369d4
@ -1,6 +1,7 @@
|
||||
foo :: Num a => a -> a
|
||||
foo = id
|
||||
{-# SPECIALIZE foo :: Int -> Int #-}
|
||||
{-# SPECIALIZE foo :: Float -> Float #-}
|
||||
|
||||
{-# SPECIALIZE [2] bar :: Int -> Int #-}
|
||||
bar :: Num a => a -> a
|
||||
|
@ -2,6 +2,7 @@ foo :: Num a => a -> a
|
||||
foo = id
|
||||
|
||||
{-# SPECIALIZE foo :: Int -> Int #-}
|
||||
{-# SPECIALIZE foo :: Float -> Float #-}
|
||||
|
||||
{-# SPECIALIZE [2] bar :: Int -> Int #-}
|
||||
|
||||
|
@ -70,6 +70,7 @@ separatedDecls (FunctionBody n) (InlinePragma n') = n /= n'
|
||||
separatedDecls (InlinePragma n) (TypeSignature n') = n /= n'
|
||||
separatedDecls (FunctionBody n) (SpecializePragma n') = n /= n'
|
||||
separatedDecls (SpecializePragma n) (TypeSignature n') = n /= n'
|
||||
separatedDecls (SpecializePragma n) (SpecializePragma n') = n /= n'
|
||||
separatedDecls _ _ = True
|
||||
|
||||
pattern TypeSignature
|
||||
|
Loading…
Reference in New Issue
Block a user