← All results

number

Group: Advanced PHPDoc types · Category: ecosystem · File: phpdoc_advanced_fallback_number.php

int|float, and nothing else — a numeric string is not a number. That is the whole distinction from numeric, which does include one. Analyzers that model the union reject the string; others fall back to mixed and accept it. References: - PHPStan TypeNodeResolver number resolves to int|float, after trying a pseudo-type class

Analyzer results

AnalyzerVersionResultDiagnostics
phan 6.0.7Phan 6.0.7 php-ast version 1.1.3 PHP version used to run Phan: 8.5.9 Unrecognized
phpdoc_advanced_fallback_number.php:21: Return type of returnsNumber() is undeclared type \Conformance\Tests\PhpdocAdvancedFallbackNumber\number (Did you mean class \BcMath\Number) [PhanUndeclaredTypeReturnType]
phpdoc_advanced_fallback_number.php:23: Returning 1 of type int (value: 1) but returnsNumber() is declared to return \Conformance\Tests\PhpdocAdvancedFallbackNumber\number (no real type) (the inferred real return type has nothing in common with the declared phpdoc return type) [PhanTypeMismatchReturnProbablyReal]
phpdoc_advanced_fallback_number.php:23: Returning 1.5 of type float (value: 1.5) but returnsNumber() is declared to return \Conformance\Tests\PhpdocAdvancedFallbackNumber\number (no real type) (the inferred real return type has nothing in common with the declared phpdoc return type) [PhanTypeMismatchReturnProbablyReal]
phpdoc_advanced_fallback_number.php:29: Parameter $value has undeclared type \Conformance\Tests\PhpdocAdvancedFallbackNumber\number (Did you mean class \BcMath\Number) [PhanUndeclaredTypeParameter]
phpdoc_advanced_fallback_number.php:36: Argument 1 ($value) is 1 of type int (value: 1) but \Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber() takes \Conformance\Tests\PhpdocAdvancedFallbackNumber\number (no real type) defined at /Users/megurine/repo/php/php-typing-conformance/conformance/tests/phpdoc_advanced_fallback_number.php:29 (the inferred real argument type has nothing in common with the parameter's phpdoc type) [PhanTypeMismatchArgumentProbablyReal]
phpdoc_advanced_fallback_number.php:37: Argument 1 ($value) is 1.5 of type float (value: 1.5) but \Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber() takes \Conformance\Tests\PhpdocAdvancedFallbackNumber\number (no real type) defined at /Users/megurine/repo/php/php-typing-conformance/conformance/tests/phpdoc_advanced_fallback_number.php:29 (the inferred real argument type has nothing in common with the parameter's phpdoc type) [PhanTypeMismatchArgumentProbablyReal]
phpdoc_advanced_fallback_number.php:40: Argument 1 ($value) is '1' of type string but \Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber() takes \Conformance\Tests\PhpdocAdvancedFallbackNumber\number (no real type) defined at /Users/megurine/repo/php/php-typing-conformance/conformance/tests/phpdoc_advanced_fallback_number.php:29 (the inferred real argument type has nothing in common with the parameter's phpdoc type) [PhanTypeMismatchArgumentProbablyReal]
phpdoc_advanced_fallback_number.php:43: Argument 1 ($value) is true of type true but \Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber() takes \Conformance\Tests\PhpdocAdvancedFallbackNumber\number (no real type) defined at /Users/megurine/repo/php/php-typing-conformance/conformance/tests/phpdoc_advanced_fallback_number.php:29 (the inferred real argument type has nothing in common with the parameter's phpdoc type) [PhanTypeMismatchArgumentProbablyReal]
  • Recognition: spelling not resolved — reported on declaration line(s) 21, 29
  • Enforcement: 2/2 of the expected violations reported — incidental, since the spelling was not resolved
Expectation diff
Line 23: Expected valid value to be accepted, got ["Returning 1 of type int (value: 1) but returnsNumber() is declared to return \\Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number (no real type) (the inferred real return type has nothing in common with the declared phpdoc return type) [PhanTypeMismatchReturnProbablyReal]","Returning 1.5 of type float (value: 1.5) but returnsNumber() is declared to return \\Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number (no real type) (the inferred real return type has nothing in common with the declared phpdoc return type) [PhanTypeMismatchReturnProbablyReal]"]
Line 36: Expected valid value to be accepted, got ["Argument 1 ($value) is 1 of type int (value: 1) but \\Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\acceptsNumber() takes \\Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number (no real type) defined at /Users/megurine/repo/php/php-typing-conformance/conformance/tests/phpdoc_advanced_fallback_number.php:29 (the inferred real argument type has nothing in common with the parameter's phpdoc type) [PhanTypeMismatchArgumentProbablyReal]"]
Line 37: Expected valid value to be accepted, got ["Argument 1 ($value) is 1.5 of type float (value: 1.5) but \\Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\acceptsNumber() takes \\Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number (no real type) defined at /Users/megurine/repo/php/php-typing-conformance/conformance/tests/phpdoc_advanced_fallback_number.php:29 (the inferred real argument type has nothing in common with the parameter's phpdoc type) [PhanTypeMismatchArgumentProbablyReal]"]
phpstan 2.2.8PHPStan - PHP Static Analysis Tool 2.2.8 Enforced reported Lv.5+
phpdoc_advanced_fallback_number.php:40: Parameter #1 $value of function Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects float|int, string given. [identifier=argument.type] [reported-from-level=5]
phpdoc_advanced_fallback_number.php:43: Parameter #1 $value of function Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects float|int, true given. [identifier=argument.type] [reported-from-level=5]
With strict-rules
phpdoc_advanced_fallback_number.php:40: Parameter #1 $value of function Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects float|int, string given. [identifier=argument.type]
phpdoc_advanced_fallback_number.php:43: Parameter #1 $value of function Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects float|int, true given. [identifier=argument.type]
  • Recognition: spelling resolved
  • Enforcement: 2/2 of the expected violations reported
psalm 6.16.1Psalm 6.16.1@f1f5de594dc76faf8784e02d3dc4716c91c6f6ac
next: 7.0.0-beta19
Unrecognized (pzoom≠)
phpdoc_advanced_fallback_number.php:19: Docblock-defined class, interface or enum named Conformance\Tests\PhpdocAdvancedFallbackNumber\number does not exist [UndefinedDocblockClass]
phpdoc_advanced_fallback_number.php:19: The declared return type 'Conformance\Tests\PhpdocAdvancedFallbackNumber\number' for Conformance\Tests\PhpdocAdvancedFallbackNumber\returnsNumber is incorrect, got '1|float(1.5)' [InvalidReturnType]
phpdoc_advanced_fallback_number.php:23: The inferred type '1|float(1.5)' does not match the declared return type 'Conformance\Tests\PhpdocAdvancedFallbackNumber\number' for Conformance\Tests\PhpdocAdvancedFallbackNumber\returnsNumber [InvalidReturnStatement]
phpdoc_advanced_fallback_number.php:27: Docblock-defined class, interface or enum named Conformance\Tests\PhpdocAdvancedFallbackNumber\number does not exist [UndefinedDocblockClass]
phpdoc_advanced_fallback_number.php:36: Argument 1 of Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but 1 provided [InvalidArgument]
phpdoc_advanced_fallback_number.php:37: Argument 1 of Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but float(1.5) provided [InvalidArgument]
phpdoc_advanced_fallback_number.php:40: Argument 1 of Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but '1' provided [InvalidArgument]
phpdoc_advanced_fallback_number.php:43: Argument 1 of Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but true provided [InvalidArgument]
pzoom (Psalm port)
phpdoc_advanced_fallback_number.php:19: Docblock class Conformance\Tests\PhpdocAdvancedFallbackNumber\number does not exist [UndefinedDocblockClass]
phpdoc_advanced_fallback_number.php:23: The type 1|1.5 does not match the declared return type Conformance\Tests\PhpdocAdvancedFallbackNumber\number [InvalidReturnStatement]
phpdoc_advanced_fallback_number.php:29: Docblock class Conformance\Tests\PhpdocAdvancedFallbackNumber\number does not exist [UndefinedDocblockClass]
phpdoc_advanced_fallback_number.php:36: Argument 1 of acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but 1 provided [InvalidArgument]
phpdoc_advanced_fallback_number.php:37: Argument 1 of acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but 1.5 provided [InvalidArgument]
phpdoc_advanced_fallback_number.php:40: Argument 1 of acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but '1' provided [InvalidArgument]
phpdoc_advanced_fallback_number.php:43: Argument 1 of acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but true provided [InvalidArgument]
  • Recognition: spelling not resolved — reported on declaration line(s) 19, 27
  • Enforcement: 2/2 of the expected violations reported — incidental, since the spelling was not resolved
Expectation diff
Line 23: Expected valid value to be accepted, got ["The inferred type '1|float(1.5)' does not match the declared return type 'Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number' for Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\returnsNumber [InvalidReturnStatement]"]
Line 36: Expected valid value to be accepted, got ["Argument 1 of Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\acceptsNumber expects Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number, but 1 provided [InvalidArgument]"]
Line 37: Expected valid value to be accepted, got ["Argument 1 of Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\acceptsNumber expects Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number, but float(1.5) provided [InvalidArgument]"]
mago 1.46.0mago 1.46.0 Unrecognized
phpdoc_advanced_fallback_number.php:19: Cannot find class, interface, enum, or type alias `Conformance\Tests\PhpdocAdvancedFallbackNumber\number`. [non-existent-class-like]
phpdoc_advanced_fallback_number.php:23: Invalid return type for function `Conformance\Tests\PhpdocAdvancedFallbackNumber\returnsNumber`: expected `unknown-ref(Conformance\Tests\PhpdocAdvancedFallbackNumber\number)`, but found `float(1.5)|int(1)`. [invalid-return-statement]
phpdoc_advanced_fallback_number.php:27: Cannot find class, interface, enum, or type alias `Conformance\Tests\PhpdocAdvancedFallbackNumber\number`. [non-existent-class-like]
phpdoc_advanced_fallback_number.php:36: Invalid argument type for argument #1 of `Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber`: expected `unknown-ref(Conformance\Tests\PhpdocAdvancedFallbackNumber\number)`, but found `int(1)`. [invalid-argument]
phpdoc_advanced_fallback_number.php:37: Invalid argument type for argument #1 of `Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber`: expected `unknown-ref(Conformance\Tests\PhpdocAdvancedFallbackNumber\number)`, but found `float(1.5)`. [invalid-argument]
phpdoc_advanced_fallback_number.php:40: Invalid argument type for argument #1 of `Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber`: expected `unknown-ref(Conformance\Tests\PhpdocAdvancedFallbackNumber\number)`, but found `string('1')`. [invalid-argument]
phpdoc_advanced_fallback_number.php:43: Invalid argument type for argument #1 of `Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber`: expected `unknown-ref(Conformance\Tests\PhpdocAdvancedFallbackNumber\number)`, but found `true`. [invalid-argument]
  • Recognition: spelling not resolved — reported on declaration line(s) 19, 27
  • Enforcement: 2/2 of the expected violations reported — incidental, since the spelling was not resolved
Expectation diff
Line 23: Expected valid value to be accepted, got ["Invalid return type for function `Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\returnsNumber`: expected `unknown-ref(Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number)`, but found `float(1.5)|int(1)`. [invalid-return-statement]"]
Line 36: Expected valid value to be accepted, got ["Invalid argument type for argument #1 of `Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\acceptsNumber`: expected `unknown-ref(Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number)`, but found `int(1)`. [invalid-argument]"]
Line 37: Expected valid value to be accepted, got ["Invalid argument type for argument #1 of `Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\acceptsNumber`: expected `unknown-ref(Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number)`, but found `float(1.5)`. [invalid-argument]"]
mir 0.70.1mir 0.70.1 Incidental (2/2)
phpdoc_advanced_fallback_number.php:36: InvalidArgument: Argument $value of acceptsNumber() expects 'Conformance\Tests\PhpdocAdvancedFallbackNumber\number', got '1' [MIR0201]
phpdoc_advanced_fallback_number.php:37: InvalidArgument: Argument $value of acceptsNumber() expects 'Conformance\Tests\PhpdocAdvancedFallbackNumber\number', got '1.5' [MIR0201]
phpdoc_advanced_fallback_number.php:40: InvalidArgument: Argument $value of acceptsNumber() expects 'Conformance\Tests\PhpdocAdvancedFallbackNumber\number', got '"1"' [MIR0201]
phpdoc_advanced_fallback_number.php:43: InvalidArgument: Argument $value of acceptsNumber() expects 'Conformance\Tests\PhpdocAdvancedFallbackNumber\number', got 'true' [MIR0201]
  • Recognition: spelling resolved
  • Enforcement: 2/2 of the expected violations reported — incidental, since values the type admits were also rejected on line(s) 36, 37
Expectation diff
Line 36: Expected valid value to be accepted, got ["InvalidArgument: Argument $value of acceptsNumber() expects 'Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number', got '1' [MIR0201]"]
Line 37: Expected valid value to be accepted, got ["InvalidArgument: Argument $value of acceptsNumber() expects 'Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number', got '1.5' [MIR0201]"]
phpantom 0.9.0phpantom_lsp 0.9.0 Enforced
phpdoc_advanced_fallback_number.php:40: Argument 1 ($value) expects number, got '1' [type_mismatch_argument]
phpdoc_advanced_fallback_number.php:43: Argument 1 ($value) expects number, got bool [type_mismatch_argument]
  • Recognition: spelling resolved
  • Enforcement: 2/2 of the expected violations reported
intelephense 1.18.5intelephense 1.18.5 Unrecognized
phpdoc_advanced_fallback_number.php:19: PHPDoc undefined type 'Conformance\Tests\PhpdocAdvancedFallbackNumber\number'. [P1133]
phpdoc_advanced_fallback_number.php:27: PHPDoc undefined type 'Conformance\Tests\PhpdocAdvancedFallbackNumber\number'. [P1133]
  • Recognition: spelling not resolved — reported on declaration line(s) 19, 27
  • Enforcement: 0/2 of the expected violations reported — incidental, since the spelling was not resolved
phpy 0.2.0phpy 0.2.0 Enforced
phpdoc_advanced_fallback_number.php:40: Argument '1' passed to Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber() is expected to be of type float|int, string given
phpdoc_advanced_fallback_number.php:43: Argument '1' passed to Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber() is expected to be of type float|int, bool given
  • Recognition: spelling resolved
  • Enforcement: 2/2 of the expected violations reported
qodana 262.8665.325Qodana 262.8665.325 Unrecognized
phpdoc_advanced_fallback_number.php:19: Return type in PHPDoc does not match the actual return type [PhpReturnDocTypeMismatchInspection]
phpdoc_advanced_fallback_number.php:40: Parameter ''1'' type is not compatible with declaration [PhpParamsInspection]
phpdoc_advanced_fallback_number.php:43: Parameter 'true' type is not compatible with declaration [PhpParamsInspection]
  • Recognition: spelling not resolved — reported on declaration line(s) 19
  • Enforcement: 2/2 of the expected violations reported — incidental, since the spelling was not resolved
noverify 0.5.5NoVerify, version 0.5.5: built on: 2025.04.22 14:36:46 OS: r-kuchinskas arm64 Commit: 4774b82f8adc53fbef38f95e97af4b953b4d1529 Unrecognized ⚠ 1 false positive
phpdoc_advanced_fallback_number.php:12: Class or interface named \Conformance\Tests\PhpdocAdvancedFallbackNumber\number does not exist [undefinedClass]
phpdoc_advanced_fallback_number.php:27: Class or interface named \Conformance\Tests\PhpdocAdvancedFallbackNumber\number does not exist [undefinedClass]
phpdoc_advanced_fallback_number.php:43: potentially not safe access in parameter value of function Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber [notSafeCall]
  • Recognition: spelling not resolved — reported on declaration line(s) 27
  • Enforcement: 1/2 of the expected violations reported — incidental, since the spelling was not resolved
  • False positives: line(s) 12
Expectation diff
Line 12: Unexpected errors ["Class or interface named \\Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number does not exist [undefinedClass]"]
steins 0.1.5steins 0.1.5 (2026-08-12 revision 39b4cc1) Enforced
phpdoc_advanced_fallback_number.php:40: argument "1" to acceptsNumber() violates declared @param number $value — declared contract violation [phpdoc.param-mismatch]
phpdoc_advanced_fallback_number.php:43: argument true to acceptsNumber() violates declared @param number $value — declared contract violation [phpdoc.param-mismatch]
  • Recognition: spelling resolved
  • Enforcement: 2/2 of the expected violations reported
phpstan-strict 2.2.8PHPStan - PHP Static Analysis Tool 2.2.8 Enforced
phpdoc_advanced_fallback_number.php:40: Parameter #1 $value of function Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects float|int, string given. [identifier=argument.type]
phpdoc_advanced_fallback_number.php:43: Parameter #1 $value of function Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects float|int, true given. [identifier=argument.type]
  • Recognition: spelling resolved
  • Enforcement: 2/2 of the expected violations reported
psalm-next 7.0.0-beta19Psalm 7.0.0-beta19@7e751c06a756fa64dc4c759c09fe4a173afcb433 Unrecognized
phpdoc_advanced_fallback_number.php:19: Docblock-defined class, interface or enum named Conformance\Tests\PhpdocAdvancedFallbackNumber\number does not exist [UndefinedDocblockClass]
phpdoc_advanced_fallback_number.php:19: The declared return type 'Conformance\Tests\PhpdocAdvancedFallbackNumber\number' for Conformance\Tests\PhpdocAdvancedFallbackNumber\returnsNumber is incorrect, got '1|float(1.5)' [InvalidReturnType]
phpdoc_advanced_fallback_number.php:23: The inferred type '1|float(1.5)' does not match the declared return type 'Conformance\Tests\PhpdocAdvancedFallbackNumber\number' for Conformance\Tests\PhpdocAdvancedFallbackNumber\returnsNumber [InvalidReturnStatement]
phpdoc_advanced_fallback_number.php:27: Docblock-defined class, interface or enum named Conformance\Tests\PhpdocAdvancedFallbackNumber\number does not exist [UndefinedDocblockClass]
phpdoc_advanced_fallback_number.php:36: Argument 1 of Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but 1 provided [InvalidArgument]
phpdoc_advanced_fallback_number.php:37: Argument 1 of Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but float(1.5) provided [InvalidArgument]
phpdoc_advanced_fallback_number.php:40: Argument 1 of Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but '1' provided [InvalidArgument]
phpdoc_advanced_fallback_number.php:43: Argument 1 of Conformance\Tests\PhpdocAdvancedFallbackNumber\acceptsNumber expects Conformance\Tests\PhpdocAdvancedFallbackNumber\number, but true provided [InvalidArgument]
  • Recognition: spelling not resolved — reported on declaration line(s) 19, 27
  • Enforcement: 2/2 of the expected violations reported — incidental, since the spelling was not resolved
Expectation diff
Line 23: Expected valid value to be accepted, got ["The inferred type '1|float(1.5)' does not match the declared return type 'Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number' for Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\returnsNumber [InvalidReturnStatement]"]
Line 36: Expected valid value to be accepted, got ["Argument 1 of Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\acceptsNumber expects Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number, but 1 provided [InvalidArgument]"]
Line 37: Expected valid value to be accepted, got ["Argument 1 of Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\acceptsNumber expects Conformance\\Tests\\PhpdocAdvancedFallbackNumber\\number, but float(1.5) provided [InvalidArgument]"]

Source

<?php

declare(strict_types=1);

namespace Conformance\Tests\PhpdocAdvancedFallbackNumber;

/**
 * `number`
 *
 * `int|float`, and nothing else — a numeric string is not a `number`. That is
 * the whole distinction from `numeric`, which does include one. Analyzers that
 * model the union reject the string; others fall back to `mixed` and accept it.
 *
 * References:
 * - PHPStan TypeNodeResolver `number` resolves to int|float, after trying a pseudo-type class
 */

/**
 * @return number
 */
function returnsNumber() // T: number
{
    return \random_int(0, 1) === 1 ? 1 : 1.5; // V
}

/**
 * @param number $value
 */
function acceptsNumber($value): void // T: number
{
}

acceptsNumber(returnsNumber()); // V

// Both members satisfy the parameter.
acceptsNumber(1); // V
acceptsNumber(1.5); // V

// A numeric string does not: `number` is narrower than `numeric`.
acceptsNumber('1'); // E?: a numeric string is not a number (int|float)

// Nor does a bool, however freely PHP would juggle it.
acceptsNumber(true); // E?: true is not a number (int|float)