```
operator ^= {
associativity right
precedence
assignment
}
```

### Declarations

Stores the result of performing a bitwise XOR operation on the two given values in the left-hand-side variable.

A bitwise XOR operation, also known as an exclusive OR operation, results
in a value that has each bit set to `1`

where *one or the other but not
both* of its arguments had that bit set to `1`

. For example:

```
var x: UInt8 = 5 // 0b00000101
let y: UInt8 = 14 // 0b00001110
x ^= y // 0b00001011
```

**Parameters:**
**lhs:** An integer value.
**rhs:** Another integer value.

#### Declaration

`func ^=(lhs: inout Int8, rhs: Int8)`

Stores the result of performing a bitwise XOR operation on the two given values in the left-hand-side variable.

A bitwise XOR operation, also known as an exclusive OR operation, results
in a value that has each bit set to `1`

where *one or the other but not
both* of its arguments had that bit set to `1`

. For example:

```
var x: UInt8 = 5 // 0b00000101
let y: UInt8 = 14 // 0b00001110
x ^= y // 0b00001011
```

**Parameters:**
**lhs:** An integer value.
**rhs:** Another integer value.

#### Declaration

`func ^=(lhs: inout Int16, rhs: Int16)`

`1`

where *one or the other but not
both* of its arguments had that bit set to `1`

. For example:

```
var x: UInt8 = 5 // 0b00000101
let y: UInt8 = 14 // 0b00001110
x ^= y // 0b00001011
```

**Parameters:**
**lhs:** An integer value.
**rhs:** Another integer value.

#### Declaration

`func ^=(lhs: inout Int32, rhs: Int32)`

`1`

where *one or the other but not
both* of its arguments had that bit set to `1`

. For example:

```
var x: UInt8 = 5 // 0b00000101
let y: UInt8 = 14 // 0b00001110
x ^= y // 0b00001011
```

**Parameters:**
**lhs:** An integer value.
**rhs:** Another integer value.

#### Declaration

`func ^=(lhs: inout Int64, rhs: Int64)`

`1`

where *one or the other but not
both* of its arguments had that bit set to `1`

. For example:

```
var x: UInt8 = 5 // 0b00000101
let y: UInt8 = 14 // 0b00001110
x ^= y // 0b00001011
```

**Parameters:**
**lhs:** An integer value.
**rhs:** Another integer value.

#### Declaration

`func ^=(lhs: inout UInt, rhs: UInt)`

`1`

where *one or the other but not
both* of its arguments had that bit set to `1`

. For example:

```
var x: UInt8 = 5 // 0b00000101
let y: UInt8 = 14 // 0b00001110
x ^= y // 0b00001011
```

**Parameters:**
**lhs:** An integer value.
**rhs:** Another integer value.

#### Declaration

`func ^=(lhs: inout UInt8, rhs: UInt8)`

`1`

where *one or the other but not
both* of its arguments had that bit set to `1`

. For example:

```
var x: UInt8 = 5 // 0b00000101
let y: UInt8 = 14 // 0b00001110
x ^= y // 0b00001011
```

**Parameters:**
**lhs:** An integer value.
**rhs:** Another integer value.

#### Declaration

`func ^=(lhs: inout UInt16, rhs: UInt16)`

`1`

where *one or the other but not
both* of its arguments had that bit set to `1`

. For example:

```
var x: UInt8 = 5 // 0b00000101
let y: UInt8 = 14 // 0b00001110
x ^= y // 0b00001011
```

**Parameters:**
**lhs:** An integer value.
**rhs:** Another integer value.

#### Declaration

`func ^=(lhs: inout UInt32, rhs: UInt32)`

`1`

where *one or the other but not
both* of its arguments had that bit set to `1`

. For example:

```
var x: UInt8 = 5 // 0b00000101
let y: UInt8 = 14 // 0b00001110
x ^= y // 0b00001011
```

**Parameters:**
**lhs:** An integer value.
**rhs:** Another integer value.

#### Declaration

`func ^=(lhs: inout UInt64, rhs: UInt64)`

Stores the result of performing a bitwise XOR operation on the two given values in the left-hand-side variable.

A bitwise XOR operation, also known as an exclusive OR operation, results in a value that has each bit set to

`1`

whereone or the other but not bothof its arguments had that bit set to`1`

. For example:Parameters:lhs:An integer value.rhs:Another integer value.## Declaration

`func ^=(lhs: inout Int, rhs: Int)`