title: why an enum value can not be used as a rvalue?
body: <h1>Note:</h1>
  
  <p>The problem has been solved. It is a bug of <code>Clion 1.2.4</code> but <strong>not the compiler</strong>. I can compile the application even if the static-analysis tool of Clion still give me an error.</p>
  
  <hr>
  
  <p>I am using <code>Clion 1.2.4</code> to build a <code>C++</code> project based on <code>C++11</code>, when I try use <code>make_shared</code> function to create a <code>shared_ptr</code> object like this:  </p>
  
  <pre><code>auto item = std::make_shared&lt;Type&gt;(EnumType::Value);
  </code></pre>
  
  <p>where <code>Type</code> is an struct with a constructor like this:</p>
  
  <pre><code>Type(EnumType t = defaultValue) { }
  </code></pre>
  
  <p>and the param of constructor is an <strong>enum</strong> type.</p>
  
  <p>But Clion give me an <em>error</em> :  </p>
  
  <pre><code>parameter type mismatch: Expression must be rvalue.
  </code></pre>
  
  <p>So I want to know whether an enum value can be used as a rvalue to call a function? And why.  </p>
  
  <hr>
  
  <p>And if I use like this:</p>
  
  <pre><code>auto item = std::make_shared&lt;Type&gt;(std::move(EnumType::Value));
  </code></pre>
  
  <p>Clion will not show the error. What the <code>move</code> function do? And is it right that using a constant value as the actual parameter of <code>move</code> function.</p>
  
  <h2>Update 2016-01-31:</h2>
  
  <p>Thank @<a href="https://stackoverflow.com/users/4342498/nathanoliver">NathanOliver</a> for the reminder. An simple example can be see <a href="http://coliru.stacked-crooked.com/a/79141096c1a93b7c" rel="nofollow noreferrer">here</a> (create by NathanOliver).</p>
  
  <p>The following is result of command <code>gcc -v</code>:</p>
  
  <pre><code>Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr --with-gxx-include-dir=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.11.sdk/usr/include/c++/4.2.1
  Apple LLVM version 7.0.0 (clang-700.0.72)
  Target: x86_64-apple-darwin14.5.0
  Thread model: posix
  </code></pre>