title: Perfect forwarding in operator[]
body: <pre><code>template &lt;typename Key, typename Resource&gt;
  class ResourceHolder {
      std::unordered_map&lt;Key, std::unique_ptr&lt;Resource&gt;&gt; resources;
  public:
      Resource&amp; get(const Key&amp; key) const {
          if (auto resource = resources.find(key); resource != std::end(resources)) {
              return *(resource-&gt;second);
          }
      }
  
      inline const Resource&amp; operator[](Key&amp;&amp; key) const {
          return get(std::forward&lt;Key&gt;(key));
      }
  };
  </code></pre>
  
  <p>I am trying to learn move semantics and I am wondering about my usage of <code>std::forward</code> inside <code>operator[]</code> - is it correct?</p>