<div>It's not used _very_ often, but it does appear a few times on Hackage. For instance, it's used several times in Agda source: <a href="https://codesearch.aelve.com/haskell/search?query=.mapKeysMonotonic&filter=Data.Map(+|$)&insensitive=off&space=off&precise=off&sources=on&page=1" title="https://codesearch.aelve.com/haskell/search?query=.mapKeysMonotonic&filter=Data.Map(+|$)&insensitive=off&space=off&precise=off&sources=on&page=1">https://codesearch.aelve.com/haskell/search?query=.mapKeysMonotonic&filter=Data.Map(+|$)&insensitive=off&space=off&precise=off&sources=on&page=1</a></div><br><div class="gmail_quote_attribution">On Apr 4 2019, at 3:19 pm, Andreas Abel <andreas.abel@ifi.lmu.de> wrote:</div><blockquote><div><div>> I doubt this function is used very often.</div><br><div>You could be mistaken. Me, too. Without statistical data, I have 0</div><div>confidence in such estimates of brain 1.</div><div>https://en.wikipedia.org/wiki/Thinking,_Fast_and_Slow</div><br><div>On 2019-04-04 14:46, Elliot Cameron wrote:</div><blockquote><div>Well I'm proposing deprecation not removal. The deprecation could even</div><div>live forever for all I care. It would point to the new name as well. Not</div><div>to mention I doubt this function is used very often.</div><br><div>On Thu, Apr 4, 2019, 2:58 AM Andreas Abel <andreas.abel@ifi.lmu.de</div><div><mailto:andreas.abel@ifi.lmu.de>> wrote:</div><br><div>I am not sure this subtlety is worth the breakage and annoyance to</div><div>users</div><div>coming with the name change.</div><div>If you think about it, renaming the keys while preserving the tree</div><div>structure cannot work if two old keys map to the same new key.</div><br><div>On 2019-04-03 17:13, Elliot Cameron wrote:</div><blockquote><div>Yeah the clearest names seem to be really long ones:</div><div>mapKeysMonotonicDistinct, mapKeysInjectiveIncreasing,</div><div>mapKeysReferToDocs, etc.</div><br><div>On Wed, Apr 3, 2019 at 11:11 AM David Feuer</div></blockquote><div><david.feuer@gmail.com <mailto:david.feuer@gmail.com></div><blockquote><div><mailto:david.feuer@gmail.com <mailto:david.feuer@gmail.com>>> wrote:</div><br><div>     We can't use "increasing" because mathematically that usually</div></blockquote><div>means</div><blockquote><div>     non-strictly increasing. Using "ascending" gets us in trouble</div></blockquote><div>with</div><blockquote><div>     the other functions in the module that use the word in a</div></blockquote><div>non-strict</div><blockquote><div>     sense.</div><br><div>     On Wed, Apr 3, 2019, 10:46 AM Elliot Cameron</div></blockquote><div><eacameron@gmail.com <mailto:eacameron@gmail.com></div><blockquote><div>     <mailto:eacameron@gmail.com <mailto:eacameron@gmail.com>>> wrote:</div><br><div>         Hello!</div><br><div>         In some recent analysis I ran into a subtlety that caught</div></blockquote><div>me by</div><blockquote><div>         surprise: Data.Map.mapKeysMonotonic has a misleading name.</div><br><div>         A monotonic function is not a strictly /increasing/ function,</div><div>         but merely non-decreasing. However,</div></blockquote><div>|mapKeysMonotonic| requires</div><blockquote><div>         that it's mapping function be injective, which means it</div></blockquote><div>really</div><blockquote><div>         only supports /increasing/ functions.</div><br><div>         valid (mapKeysMonotonic (\x->  if  x`elem`  [1,2]then  2</div></blockquote><div>else  x) (fromList [(1,"a"), (2,"b"), (3,"c")]))==  False</div><blockquote><br><div>         The docs hint at this with "This means that @f</div><div>         <https://github.com/f>@ maps distinct original keys to</div></blockquote><div>distinct</div><blockquote><div>         resulting keys."</div><br><div>         However, I'd propose that we deprecate this name and</div></blockquote><div>rename to</div><blockquote><div>         something like |mapKeysIncreasing|or |mapKeysAsc| (to</div></blockquote><div>follow the</div><blockquote><div>         pattern of other *Asc functions). We should also clarify</div></blockquote><div>the docs.</div><blockquote><br><br><div>          From https://github.com/haskell/containers/issues/617</div><div>         _______________________________________________</div><div>         Libraries mailing list</div><div>Libraries@haskell.org <mailto:Libraries@haskell.org></div></blockquote><div><mailto:Libraries@haskell.org <mailto:Libraries@haskell.org>></div><blockquote><div>http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries</div><br><br><div>_______________________________________________</div><div>Libraries mailing list</div><div>Libraries@haskell.org <mailto:Libraries@haskell.org></div><div>http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries</div></blockquote><div>_______________________________________________</div><div>Libraries mailing list</div><div>Libraries@haskell.org <mailto:Libraries@haskell.org></div><div>http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries</div></blockquote><div>_______________________________________________</div><div>Libraries mailing list</div><div>Libraries@haskell.org</div><div>http://mail.haskell.org/cgi-bin/mailman/listinfo/libraries</div></div></blockquote>