fork download
  1. #include <iostream>
  2. #include <type_traits>
  3.  
  4. int main(int argc, const char *argv[])
  5. {
  6. std::remove_pointer<const int>::type i0 = 10; // ok. type is const int. must be initialized
  7. std::remove_pointer<const int *>::type i1 = 10; // ok. type is const int. must be initialized.
  8. std::remove_pointer<int const *>::type i2 = 10; // ok. type is const int. must be initialized.
  9. std::remove_pointer<int * const>::type i3; // ok. type is int. no initialization needed
  10.  
  11. return 0;
  12. }
  13.  
Success #stdin #stdout 0s 3292KB
stdin
Standard input is empty
stdout
Standard output is empty