summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorPete Kinnecom <git@k7u7.com>2017-09-18 09:47:29 -0700
committerPete Kinnecom <git@k7u7.com>2017-09-21 21:20:19 -0700
commitef6398aa8fc91ac318373601d8b24f55b62da4ba (patch)
treebd33de6256ed43b8c593907be8febda3d77613f8 /lib
parentdc7a240d07a7b6a2b9f20827bb2a661ed2311a20 (diff)
downloadpsych-ef6398aa8fc91ac318373601d8b24f55b62da4ba.zip
Fixup Recorder example documentation
Diffstat (limited to 'lib')
-rw-r--r--lib/psych.rb9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/psych.rb b/lib/psych.rb
index e93ac8f..2888774 100644
--- a/lib/psych.rb
+++ b/lib/psych.rb
@@ -198,12 +198,13 @@ require 'psych/class_loader'
#
# ==== Receiving an events stream
#
-# parser = Psych::Parser.new(Psych::Handlers::Recorder.new)
+# recorder = Psych::Handlers::Recorder.new
+# parser = Psych::Parser.new(recorder)
#
# parser.parse("---\n - a\n - b")
-# parser.events # => [list of [event, args] lists]
-# # event is one of: Psych::Handler::EVENTS
-# # args are the arguments passed to the event
+# recorder.events # => [list of [event, args] lists]
+# # event is one of: Psych::Handler::EVENTS
+# # args are the arguments passed to the event
#
# === Emitting
#