Q:

What's the difference between "and_eq" and "&="?

I've been looking at the c++ reference site, and I came across this article about the and_eq keyword. This article said:

alternative operators: as an alternative for &=

about the and_eq operator. I could not find anything online about the difference between and_eq and &=. Is it exactly the same as the &= operator, or is there a difference? If there is a difference, when should I use each?

A:

If you click through the "alternative operators" link on the very page you've linked, you'll see this text:

There are alternative spellings for several operators and other tokens that use non-ISO646 characters. In all respects of the language, each alternative token behaves exactly the same as its primary token, except for its spelling (the stringification operator can make the spelling visible). The two-letter alternative tokens are sometimes called "digraphs" 

Note that certain compilers are non-standard by default and don't allow for alternative spellings, so you'll either enforce the standard compliance mode to make it possible to use the alternative spellings, or just use the primary ones.

