Sha256: d434097fd0ce92c13aa8c95c39c37fcc10aeec6ceedc295bc1a32582df87f032
Contents?: true
Size: 287 Bytes
Versions: 1
Compression:
Stored size: 287 Bytes
Contents
require 'syntax_finder' # Check def with paren or no paren class IfThenFinder < SyntaxFinder def look node if node.type == :def_node has_params = !node.parameters.nil? has_paren = !node.lparen_loc.nil? inc paren: has_paren, params: has_params end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
syntax_finder-0.1.0 | samples/def_paren_finder.rb |