Access is a Behaviour, so this library needs to be updated to support it. Try,
@behaviour Access
def get(tree, key) do
RedBlackTree.get(tree, key)
end
def get_and_update(tree, key, fun) do
{get, update} = fun.(RedBlackTree.get(tree, key))
{get, RedBlackTree.insert(tree, key, update)}
end
Elixir uses Map's now, not Dict's:
warning: use Dict is deprecated, use the Map module for working with maps or the Keyword module for working with keyword lists
lib/red_black_tree.ex:16
also,
warning: function slice/1 required by protocol Enumerable is not implemented (in module Enumerable.RedBlackTree)
lib/red_black_tree.ex:627
Access is a Behaviour, so this library needs to be updated to support it. Try,
Elixir uses
Map
's now, notDict
's:also,