質問編集履歴

1

operator==は定義してなかったので、サンプルコードも定義していなかったバージョンに合わせた

2022/04/04 15:02

投稿

fdaskjlfda
fdaskjlfda

スコア40

test CHANGED
File without changes
test CHANGED
@@ -23,9 +23,6 @@
23
23
  CustomInt hoge = {0};
24
24
  std::cout << hoge << std::endl;
25
25
  hoge = 20;
26
- if (hoge == 30) {
27
- std::cout << "hoge is 30" << std::endl;
28
- }
29
26
  std::cout << std::pow(static_cast<int>(hoge), 2) << std::endl;
30
27
 
31
28
  // 2