### Revision history for KeyPgOpXor

##### Deletions:

##### Additions:

##### Additions:

[[KeyPgDeclare|declare]] [[KeyPgOperator|operator]] **Xor** ( [[KeyPgByref|byref]] //lhs// [[KeyPgAs|as]] //T1//, [[KeyPgByref|byref]] //rhs// [[KeyPgAs|as]] //T2// ) [[KeyPgAs|as]] //Ret//

The return type depends on the types of values passed. ##[[KeyPgByte|Byte]]##, ##[[KeyPgUbyte|Ubyte]]## and floating-point type values are first converted to ##[[KeyPgInteger|Integer]]##. If the left and right-hand side types differ only in signedness, then the return type is the same as the left-hand side type (##//T1//##), otherwise, the larger of the two types is returned. Only if the left and right-hand side types are both ##[[KeyPgBoolean|Boolean]]##, the return type is also ##[[KeyPgBoolean|Boolean]]##.

- In the //[[CompilerOptlang|-lang qb]]// dialect, this operator cannot be overloaded.

- [[TblTruth|Operator Truth Tables]]

The return type depends on the types of values passed. ##[[KeyPgByte|Byte]]##, ##[[KeyPgUbyte|Ubyte]]## and floating-point type values are first converted to ##[[KeyPgInteger|Integer]]##. If the left and right-hand side types differ only in signedness, then the return type is the same as the left-hand side type (##//T1//##), otherwise, the larger of the two types is returned. Only if the left and right-hand side types are both ##[[KeyPgBoolean|Boolean]]##, the return type is also ##[[KeyPgBoolean|Boolean]]##.

- In the //[[CompilerOptlang|-lang qb]]// dialect, this operator cannot be overloaded.

- [[TblTruth|Operator Truth Tables]]

##### Deletions:

The return type depends on the types of values passed. ##[[KeyPgByte Byte]]##, ##[[KeyPgUbyte Ubyte]]## and floating-point type values are first converted to ##[[KeyPgInteger Integer]]##. If the left and right-hand side types differ only in signedness, then the return type is the same as the left-hand side type (##//T1//##), otherwise, the larger of the two types is returned. Only if the left and right-hand side types are both ##[[KeyPgBoolean Boolean]]##, the return type is also ##[[KeyPgBoolean Boolean]]##.

- In the //[[CompilerOptlang -lang qb]]// dialect, this operator cannot be overloaded.

- [[TblTruth Operator Truth Tables]]

#### Revision [17788]

Edited on 2015-09-12 08:13:14 by FxMwikki [Added the case for a boolean return type]##### Additions:

The return type depends on the types of values passed. ##[[KeyPgByte Byte]]##, ##[[KeyPgUbyte Ubyte]]## and floating-point type values are first converted to ##[[KeyPgInteger Integer]]##. If the left and right-hand side types differ only in signedness, then the return type is the same as the left-hand side type (##//T1//##), otherwise, the larger of the two types is returned. Only if the left and right-hand side types are both ##[[KeyPgBoolean Boolean]]##, the return type is also ##[[KeyPgBoolean Boolean]]##.

##### Deletions:

#### Revision [17773]

Edited on 2015-09-12 07:17:07 by FxMwikki [Added conversion of Booleans to Integers]##### Additions:

This operator returns the bitwise-exclusion of its operands, a logical operation that results in a value with bits set depending on the bits of the operands (for conversion of a boolean to an integer, false or true boolean value becomes 0 or -1 integer value).

##### Deletions:

##### Additions:

Any numeric or boolean type.

Any numeric or boolean type.

A numeric or boolean type (varies with ##//T1//## and ##//T2//##).

Any numeric or boolean type.

A numeric or boolean type (varies with ##//T1//## and ##//T2//##).

##### Deletions:

Any numeric type.

A numeric type (varies with ##//T1//## and ##//T2//##).