Method: RDoc::Parser::Ruby#get_bool
- Defined in:
- lib/rdoc/parser/ruby.rb
#get_bool ⇒ Object
Looks for a true or false token.
327 328 329 330 331 332 333 334 335 336 337 338 |
# File 'lib/rdoc/parser/ruby.rb', line 327 def get_bool skip_tkspace tk = get_tk if :on_kw == tk[:kind] && 'true' == tk[:text] true elsif :on_kw == tk[:kind] && ('false' == tk[:text] || 'nil' == tk[:text]) false else unget_tk tk true end end |