4 ms·
I don't see what special about double brackets? It's just calling the operator again on the result, completely intuitive.
by sudosysgen 4y ago
I don't see what special about double brackets? It's just calling the operator again on the result, completely intuitive.
- edflsafoiewq 4y agoHe means attributes, eg [[nodiscard]]. Of course you shouldn't call them operators.
- MauranKilom 4y agoSee, I assumed they meant the >> operator. That used to (long ago) be cause for grief in e.g. std::vector<std::vector<int>> where the parser would see a >> operator instead of two closing angle brackets (since fixed by changing the grammar).
- tialaramex 4y agoSo, there are four things which might get colloquially called "Brackets", they each have other names but... (Round) brackets are Parentheses {Curly} brackets are Braces <Angle> brackets are Chevrons [Square] brackets are often just Brackets Ah, so there's the problem. Now, this actually also differs depending on English variant. In England it would be pretty normal to say "Brackets" and mean Parentheses, whereas in the US you'd mean the square brackets. Some English speakers outside the US might call the Square Brackets "Crotchets" to distinguish them, not so many. US English dominates in technology.