1af4f2eb4SDaniel // RUN: %check_clang_tidy %s cppcoreguidelines-pro-type-member-init,hicpp-member-init,modernize-use-emplace,hicpp-use-emplace %t -- \ 2*e8a3ddafSNathan James //// RUN: -config='{CheckOptions: { \ 3*e8a3ddafSNathan James //// RUN: cppcoreguidelines-pro-type-member-init.UseAssignment: true, \ 4*e8a3ddafSNathan James //// RUN: }}' 5af4f2eb4SDaniel 6af4f2eb4SDaniel class Foo { 7af4f2eb4SDaniel public: Foo()8af4f2eb4SDaniel Foo() : _num1(0) 9af4f2eb4SDaniel // CHECK-MESSAGES: warning: constructor does not initialize these fields: _num2 [cppcoreguidelines-pro-type-member-init,hicpp-member-init] 10af4f2eb4SDaniel // CHECK-MESSAGES: note: cannot apply fix-it because an alias checker has suggested a different fix-it; please remove one of the checkers ('cppcoreguidelines-pro-type-member-init', 'hicpp-member-init') or ensure they are both configured the same 11af4f2eb4SDaniel { 12af4f2eb4SDaniel _num1 = 10; 13af4f2eb4SDaniel } 14af4f2eb4SDaniel use_the_members() const15af4f2eb4SDaniel int use_the_members() const { 16af4f2eb4SDaniel return _num1 + _num2; 17af4f2eb4SDaniel } 18af4f2eb4SDaniel 19af4f2eb4SDaniel private: 20af4f2eb4SDaniel int _num1; 21af4f2eb4SDaniel int _num2; 22af4f2eb4SDaniel // CHECK-FIXES: _num2; 23af4f2eb4SDaniel }; 24