Skip to content

Instantly share code, notes, and snippets.

@sevenseacat
Created December 7, 2018 16:46
Show Gist options
  • Save sevenseacat/e8bcd320fb7c5cf8d1e02694e6e48110 to your computer and use it in GitHub Desktop.
Save sevenseacat/e8bcd320fb7c5cf8d1e02694e6e48110 to your computer and use it in GitHub Desktop.
iex(40)> :ets.new(:foo3, [:set, :named_table])
:foo3
iex(41)> :ets.insert(:foo3, {"a", 1})
true
iex(42)> :ets.lookup(:foo3, "a")
[{"a", 1}]
iex(43)> :ets.update_counter(:foo3, "a", {0, -1, 0, 0})
** (ArgumentError) argument error
(stdlib) :ets.update_counter(:foo3, "a", {0, -1, 0, 0})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment