File tree Expand file tree Collapse file tree 1 file changed +25
-25
lines changed
Expand file tree Collapse file tree 1 file changed +25
-25
lines changed Original file line number Diff line number Diff line change @@ -1244,36 +1244,36 @@ void compiler<Registry>::select_dominant_overriders(
12441244 return ;
12451245 }
12461246
1247- if constexpr (!Registry::template has_policy<policies::n2216>) {
1248- return ;
1249- }
1250-
1251- if (!candidates[pick]->covariant_return_type ) {
1252- return ;
1253- }
1254-
1255- remaining = 0 ;
1256-
1257- for (size_t i = 0 ; i < candidates.size (); ++i) {
1258- if (candidates[i]) {
1259- for (size_t j = i + 1 ; j < candidates.size (); ++j) {
1260- if (candidates[j]) {
1261- BOOST_ASSERT (candidates[i] != candidates[j]);
1247+ if constexpr (Registry::template has_policy<policies::n2216>) {
1248+ if (!candidates[pick]->covariant_return_type ) {
1249+ return ;
1250+ }
12621251
1263- if (candidates[i]->covariant_return_type ->is_base_of (
1264- candidates[j]->covariant_return_type )) {
1265- candidates[i] = nullptr ;
1266- } else if (candidates[j]->covariant_return_type ->is_base_of (
1267- candidates[i]->covariant_return_type )) {
1268- candidates[j] = nullptr ;
1252+ remaining = 0 ;
1253+
1254+ for (size_t i = 0 ; i < candidates.size (); ++i) {
1255+ if (candidates[i]) {
1256+ for (size_t j = i + 1 ; j < candidates.size (); ++j) {
1257+ if (candidates[j]) {
1258+ BOOST_ASSERT (candidates[i] != candidates[j]);
1259+
1260+ if (candidates[i]->covariant_return_type ->is_base_of (
1261+ candidates[j]->covariant_return_type )) {
1262+ candidates[i] = nullptr ;
1263+ } else if (candidates[j]
1264+ ->covariant_return_type ->is_base_of (
1265+ candidates[i]
1266+ ->covariant_return_type )) {
1267+ candidates[j] = nullptr ;
1268+ }
12691269 }
12701270 }
12711271 }
1272- }
12731272
1274- if (candidates[i]) {
1275- pick = i;
1276- ++remaining;
1273+ if (candidates[i]) {
1274+ pick = i;
1275+ ++remaining;
1276+ }
12771277 }
12781278 }
12791279}
You can’t perform that action at this time.
0 commit comments