Skip to content

Commit

Permalink
[Doc] Tweak example of Prism::Dispatcher
Browse files Browse the repository at this point in the history
This PR tweaked the documentation to correct an error encountered
when running the example code of `Prism::Dispatcher`.
This aims to make understanding the example smoother.
  • Loading branch information
koic committed Jul 17, 2024
1 parent 9e9b069 commit 4668548
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion templates/lib/prism/dispatcher.rb.erb
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ module Prism
# end
# end
#
# dispatcher = Dispatcher.new
# listener = OctalListener.new
# dispatcher = Prism::Dispatcher.new
# dispatcher.register(listener, :on_integer_node_enter)
#
# Then, you can walk any number of trees and dispatch events to the listeners:
Expand Down

0 comments on commit 4668548

Please sign in to comment.