File tree Expand file tree Collapse file tree 1 file changed +31
-0
lines changed
Expand file tree Collapse file tree 1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change @@ -54,6 +54,37 @@ in a range-based for loop:
5454The check also supports custom pair-like types via the :option: `PairTypes `
5555option.
5656
57+ Limitations
58+ -----------
59+
60+ The check currently ignores variables defined with attributes or qualifiers
61+ except const and & since it's not very common:
62+
63+ .. code-block :: c++
64+
65+ static auto pair = getPair();
66+ static int b = pair.first;
67+ static int c = pair.second;
68+
69+ The check doesn't check for some situations which could possibly transfered
70+ to structured bnindings, for example:
71+
72+ .. code-block :: c++
73+
74+ const auto& results = mapping.try_emplace("hello!");
75+ const iterator& it = results.first;
76+ bool succeed = results.second;
77+ // succeed is not changed in the following code
78+
79+ and:
80+
81+ .. code-block :: c++
82+
83+ const auto results = mapping.try_emplace("hello!");
84+ if (results.second) {
85+ handle_inserted(results.first);
86+ }
87+
5788Options
5889-------
5990
You can’t perform that action at this time.
0 commit comments