php8.5
Home/ Manual/ swoole / atomic/ Swoole\Atomic::sub

Swoole\Atomic::sub

PHP function Edit on GitHub ✎

(PECL swoole >= 1.9.0)

Subtract a number to the value of the atomic object.

Description

Swoole\Atomic::sub([int $sub_value]): int

Subtract a number to the value of the atomic object.

Parameters

sub_value

The value which will be subtracted to the current value.

Return Values

The current value of the atomic object.

Source: reference/swoole/swoole/atomic/sub.xml · from the official PHP manual (php/doc-en)