Home > Back-end >  C &=is with the operation?
C &=is with the operation?

Time:10-07


 
QPainterPath QPP;
QPP & amp;=QPainterPath ();

The above is reading a big code, you see, of course, it is not in the original, behind the and operation in a function, the bitwise and a number I can understand that, but here the press with an instance of a class, what is this SAO operation, seek to reassure bosses,

CodePudding user response:

May be overloaded operators

CodePudding user response:

A + 1=====& gt; A=a + 1
QPP & amp;=QPainterPath ()===========& gt; QPP=QPP & amp; QPainterPath ()

CodePudding user response:

refer to the second floor yshuise response:
a + 1=====& gt; A=a + 1
QPP & amp;=QPainterPath ()===========& gt; QPP=QPP & amp; QPainterPath ()
you didn't see clear problem
Note that
QPP is QPainterPath object
QPainterPath () is the constructor

This is overloaded & amp;=operator
And binary & amp; There is no necessary connection

CodePudding user response:

https://doc.qt.io/Qt-5/qpainterpath.html#operator-and-eq

CodePudding user response:

reference lin5161678 reply: 3/f
Quote: refer to the second floor yshuise response:
a + 1=====& gt; A=a + 1
QPP & amp;=QPainterPath ()===========& gt; QPP=QPP & amp; QPainterPath ()
you didn't see clear problem
Note that
QPP is QPainterPath object
QPainterPath () is the constructor

This is overloaded & amp;=operator
And binary & amp; There is no necessary connection
well, who can say of, or don't understand, searched so no similar problems, or may be I couldn't call its name, can't find the right word search
  • Related