title: Why do method declarations evaluate to nil in ruby?
body: <p>Defining a method doesn't seem to evaluate to a truthy value as can be checked by putting one inside an <code>if</code> condition:</p>
  
  <pre><code>if(def some_method; puts "random text"; end) then
    puts "declaration evaluates to true"
  else
    puts "declaration evaluates to false"
  end
  # =&gt; declaration evaluates to false
  </code></pre>
  
  <p>Why/How does a method declaration evaluate to <code>nil</code>?</p>