using Php;

namespace PhpNative {
    public int strlen (string value) {
        return value.length;
    }

    public int strlen_static (string value, string php_file, int php_line) throws Error {
        return strlen (value);
    }

    public zval strlen_zval (zval value, string php_file, int php_line) throws Error {
        return zval.integer (strlen_static (zval_to_string (value), php_file, php_line));
    }
}
