WordPress at a glance
function is not described

ParagonIE_Sodium_Compat::add() public WP 1.0

Add two numbers (little-endian unsigned), storing the value in the first parameter.

This mutates $val.

{} It's a method of the class: ParagonIE_Sodium_Compat{}

No Hooks.

Return

null. Null. Nothing.

Usage

$result = ParagonIE_Sodium_Compat::add( $val, $addv );
$val(string) (required)
-
$addv(string) (required)
-

Code of ParagonIE_Sodium_Compat::add() WP 5.7.1

<?php
public static function add(&$val, $addv)
{
    $val_len = ParagonIE_Sodium_Core_Util::strlen($val);
    $addv_len = ParagonIE_Sodium_Core_Util::strlen($addv);
    if ($val_len !== $addv_len) {
        throw new SodiumException('values must have the same length');
    }
    $A = ParagonIE_Sodium_Core_Util::stringToIntArray($val);
    $B = ParagonIE_Sodium_Core_Util::stringToIntArray($addv);

    $c = 0;
    for ($i = 0; $i < $val_len; $i++) {
        $c += ($A[$i] + $B[$i]);
        $A[$i] = ($c & 0xff);
        $c >>= 8;
    }
    $val = ParagonIE_Sodium_Core_Util::intArrayToString($A);
}