README.md in mem-0.0.2 vs README.md in mem-0.1.0
- old
+ new
@@ -7,22 +7,22 @@
```
## Usage
```ruby
class Foo
- extend Mem
+ include Mem
def initialize
@count = 0
end
def bar
baz
end
# `memoize` defines bar_with_memoize & bar_without_memoize,
- # and the result of the 1st method call is stored into @bar.
+ # and the result of the 1st method call is stored into @memoized_table.
memoize :bar
private
def baz
@@ -32,6 +32,9 @@
foo = Foo.new
foo.bar #=> 1
foo.bar #=> 1
foo.bar #=> 1
+foo.has_memoized?(:bar) #=> true
+foo.memoized(:bar) #=> 1
+foo.memoized_table #=> { bar: 1 }
```