title: Variadic template specilization
body: <p>So I was trying the custom literal operator in order to implement binary literals. However it seems I am doing something wrong with the template specialization. The static_assert is evaluated while it shouldn't:</p>
  
  <pre><code>template &lt;char... bits&gt;
  struct bin_imp
  {
          static constexpr unsigned long long to_ull()
          {
                  static_assert(false,"not binary value");
                  return 0;
          }
  };
  
  template &lt;char... bits&gt;
  struct bin_imp&lt;'0', bits...&gt;
  {
          static constexpr unsigned long long to_ull()
          {
                  return bin_imp&lt;bits...&gt;::to_ull();
          }
  };
  
  template &lt;char... bits&gt;
  struct bin_imp&lt;'1', bits...&gt;
  {
          static constexpr unsigned long long to_ull()
          {
                  return (1ULL &lt;&lt; sizeof...(bits)) | bin_imp&lt;bits...&gt;::to_ull();
          }
  };
  
  
  template &lt;&gt;
  struct bin_imp&lt;&gt;
  {
          static constexpr unsigned long long to_ull()
          {
                  return 0;
          }
  };
  
  template &lt;char... bits&gt;
  static constexpr unsigned long long operator "" _b ()
  {
          return bin_imp&lt;bits...&gt;::to_ull();
  };
  
  int main(int argc, char* argv[])
  {
          unsigned int i = 11_b;
          return 0;
  }
  </code></pre>
  
  <p>Any ideas?</p>