Lines Matching +full:u +full:- +full:magic

29     public static $parsedLineNumber = -1;
127 return $value->format('c');
129 return sprintf('!php/const %s::%s', \get_class($value), $value->name);
132 return '!'.$value->getTag().' '.self::dump($value->getValue(), $flags);
194 case Parser::preg_match('{^[0-9]+[_0-9]*$}', $value):
206 * @param array|\ArrayObject|\stdClass $value The PHP array or array-like object to check
304 … // a non-quoted string cannot start with @ or ` (reserved) nor with a scalar indicator (| or >)
328 $output = substr($match[0], 1, -1);
332 $output = $unescaper->unescapeDoubleQuotedString($output);
334 $output = $unescaper->unescapeSingleQuotedString($output);
393 --$i;
543 --$i;
555 * Evaluates scalars and replaces magic values.
568 $value = substr($scalar, 1, $pos - 2);
651 …sprintf('The string "%s" could not be parsed as it uses an unsupported built-in tag.', $scalar), s…
652 case preg_match('/^(?:\+|-)?0o(?P<value>[0-7_]++)$/', $scalar, $matches):
655 if ('-' === $scalar[0]) {
656 return -octdec($value);
660 case \in_array($scalar[0], ['+', '-', '.'], true) || is_numeric($scalar[0]):
661 if (Parser::preg_match('{^[+-]?[0-9][0-9_]*$}', $scalar)) {
667 if (preg_match('/^0[0-7]+$/', $scalar)) {
676 case '-' === $scalar[0] && ctype_digit(substr($scalar, 1)):
677 if (preg_match('/^-0[0-7]+$/', $scalar)) {
678 … be parsed as strings as of 6.0. Use "%s" to represent the octal number.', '-0o'.substr($scalar, 2…
680 return -octdec(substr($scalar, 1));
693 return -log(0);
694 case '-.inf' === $scalarLower:
696 case Parser::preg_match('/^(-|\+)?[0-9][0-9_]*(\.[0-9_]+)?$/', $scalar):
707 if (false !== $scalar = $time->getTimestamp()) {
711 // no-op
714 return $time->format('U');
737 // Is followed by a scalar and is a built-in tag
745 // Built-in tags
747 …throw new ParseException(sprintf('The built-in tag "!%s" is not implemented.', $tag), self::$parse…
769 if (!Parser::preg_match('#^[A-Z0-9+/]+={0,2}$#i', $parsedBinaryData)) {
778 return !preg_match('//u', $value) || preg_match('/[^\x00\x07-\x0d\x1B\x20-\xff]/', $value);
790 (?P<year>[0-9][0-9][0-9][0-9])
791 -(?P<month>[0-9][0-9]?)
792 -(?P<day>[0-9][0-9]?)
794 (?P<hour>[0-9][0-9]?)
795 :(?P<minute>[0-9][0-9])
796 :(?P<second>[0-9][0-9])
797 (?:\.(?P<fraction>[0-9]*))?
798 (?:[ \t]*(?P<tz>Z|(?P<tz_sign>[-+])(?P<tz_hour>[0-9][0-9]?)
799 (?::(?P<tz_minute>[0-9][0-9]))?))?)?
809 return '~^0x[0-9a-f_]++$~i';