title: Scala error: value <FUNCTION_NAME> is not a member of object <OBJECT_NAME>
body: <p><strong>LATER EDIT:</strong> </p>
  
  <ul>
  <li>Related questions: </li>
  </ul>
  
  <p><a href="https://stackoverflow.com/questions/30495571/why-are-scala-class-methods-not-first-class-citizens?rq=1">Why are Scala class methods not first-class citizens?</a></p>
  
  <p><a href="https://stackoverflow.com/a/25763401/4511978">Motivation for Scala underscore in terms of formal language theory and good style?</a></p>
  
  <p>Usage of the <code>_</code> wildcard, or <em>placeholder syntax</em>: <a href="https://stackoverflow.com/questions/8260367/scala-placeholder-syntax">Scala placeholder syntax</a></p>
  
  <ul>
  <li>In this question I was trying to achieve a more compact syntax, and the solution involved the so-called <em>placeholder syntax</em>. This viewpoint is reinforced in Jason Swartz's <a href="https://www.safaribooksonline.com/library/view/learning-scala/9781449368814/" rel="nofollow noreferrer">Learning Scala</a>, page 74:</li>
  </ul>
  
  <blockquote>
    <p>Placeholder syntax is especially helpful when working with data structures and collections. Many of the core sorting, filtering, and other data structure methods tend to use
    first-class functions, and placeholder syntax reduces the amount of extra code required
    to call these methods.</p>
  </blockquote>
  
  <hr>
  
  <p><strong>QUESTION BODY</strong></p>
  
  <p>I'm trying out Scala's support for first-order functions, and encountered <a href="https://stackoverflow.com/questions/17414994/how-to-pass-a-class-method-as-a-parameter-in-scala">this</a> problem, about passing methods as parameters. As far as I understood, the solution is to wrap the method with a (named or anonymous) first-order function. This worked for me:</p>
  
  <pre><code>def wrapperFn(s:String):String = s.reverse
  </code></pre>
  
  <p><code>wrapperFn</code> can be now passed as parameter to other higher-order functions, or as value to other definitions like this one:</p>
  
  <pre><code>val otherGoodFn:(String=&gt;String) = goodWrapperFn
  </code></pre>
  
  <p>So far so good. The problem came when I tried to mix both steps (avoiding the somewhat verbose use of the <code>s</code> parameter), and directly pass the method to a function-typed value, like this:</p>
  
  <pre><code>def errorFn:(String=&gt;String) = String.reverse
  </code></pre>
  
  <p>Which throws the following error:</p>
  
  <pre><code>error: value reverse is not a member of object String
     def errorFn:(String=&gt;String) = String.reverse
                                                  ^
  </code></pre>
  
  <p>Which I don't understand, because this works as expected:</p>
  
  <pre><code>val s:String = "hello"
  s.reverse
  </code></pre>
  
  <p>So apparently the method is a member of the instance, but not of the Object/Class(??) It seems that Scala handles the class and object lifetime in a very different way as Java does. So my question, now more concisely:</p>
  
  <ul>
  <li><strong>Is the error caused by some stupid mistake or is it indeed not allowed? And if not allowed, why?</strong></li>
  </ul>
  
  <p>Thanks in advance!</p>