packages feed

yaml-marked 0.2.0.0 → 0.2.0.1

raw patch · 4 files changed

+15/−3 lines, 4 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

Files

CHANGELOG.md view
@@ -1,4 +1,8 @@-## [_Unreleased_](https://github.com/pbrisbin/yaml-marked/compare/v0.1.0.0...main)+## [_Unreleased_](https://github.com/pbrisbin/yaml-marked/compare/v0.2.0.1...main)++## [v0.2.0.1](https://github.com/pbrisbin/yaml-marked/compare/v0.2.0.0...v0.2.0.1)++- Correctly accept adjacent replaces as non-overlapping  ## [v0.2.0.0](https://github.com/pbrisbin/yaml-marked/compare/v0.1.0.0...v0.2.0.0) 
src/Data/Yaml/Marked/Replace.hs view
@@ -108,7 +108,7 @@     | otherwise = go (acc <> [r]) rs  precedesEndOf :: Replace -> Replace -> Bool-precedesEndOf a b = replaceIndex a <= replaceIndex b + replacedLength b+precedesEndOf a b = replaceIndex a < replaceIndex b + replacedLength b  -- | Break a 'ByteString' into the content before/after a replacement --
test/Data/Yaml/Marked/ReplaceSpec.hs view
@@ -35,6 +35,14 @@       runReplaces rs "this text will be hot"         `shouldReturn` "that text won't be cold" +    it "works for adjacent replaces" $ do+      let rs =+            [ newReplace 0 4 ""+            , newReplace 4 4 ""+            ]++      runReplaces rs "012\n012\n012\n" `shouldReturn` "012\n"+     context "validations" $ do       it "ReplaceOutOfBounds" $ do         let r = newReplace 0 3 ""
yaml-marked.cabal view
@@ -1,6 +1,6 @@ cabal-version:   1.18 name:            yaml-marked-version:         0.2.0.0+version:         0.2.0.1 license:         MIT license-file:    LICENSE maintainer:      Pat Brisbin <pbrisbin@gmail.com>