title: Compiler attribute stuck on a function type - is there a workaround for this clang-cl bug?
body: <p>When using the C++ LLVM-vs2014 configuration in Visual Studio 2015, this static assert fails. The assert does not fail in clang++, gcc, or even Visual C++. The <a href="http://clang.llvm.org/docs/AttributeReference.html#thiscall-gnu-thiscall-thiscall-thiscall" rel="nofollow"><code>thiscall</code></a> attribute is stuck on the function type, even though it's no longer applicable. I've filed a bug report, but I'd like to know if there's a way to forcefully remove the attribute in the meantime. Can <code>thiscall</code> be removed?</p>
  
  <pre><code>#include &lt;type_traits&gt;
  
  template&lt;typename T&gt;
  struct remove_member_pointer;
  
  template&lt;typename T, typename U&gt;
  struct remove_member_pointer&lt;T U::*&gt; {
      using type = T;
  };
  
  struct foo;
  
  using input = void(foo::*)();
  using expect = void();
  using result = typename remove_member_pointer&lt;input&gt;::type;
  
  //This static_assert fails because there is a
  //compiler-generated attribute left behind, making
  //the type of result actually `void () __attribute__((thiscall))`
  static_assert(std::is_same&lt;result, expect&gt;{}, "");
  
  int main() { return{}; }
  </code></pre>
  
  <p>Microsoft Visual Studio Community 2015
  Version 14.0.24720.00 Update 1</p>