facebook / facebook/hhvm

Printing non-serializable classes in the debugger says they're null

Abierto
#3,829 0 comentarios 0 reacciones 1 asignado Reclamado por @paulbiss Ver en GitHub
Lenguaje dominante
C++
Estrellas
18.7k
Forks
3.1k
Merge medio
1 h 47 min
PR fusionados (30 d)
2

Descripción

```
hphpd> $x = new ReflectionFunction('mb_ereg_replace')
hphpd> p $x
null
hphpd> p (string) $x
"/**\n * @param mixed \$pattern - The regular expression pattern. Multibyte\n * characters may be used in pattern.\n * @param string \$replacement - The replacement text.\n * @param string \$str - The string being checked.\n * @param string \$option - Matching condition can be set by option parameter.\n * If i is specified for this parameter, the case will be ignored. If x is\n * specified, white space will be ignored. If m is specified, match will be\n * executed in multiline mode and line break will be included in '.'. If p is\n * specified, match will be executed in POSIX mode, line break will be\n * considered as normal character. If e is specified, replacement string will\n * be evaluated as PHP expression.\n *\n * @return mixed - The resultant string on success, or FALSE on error.\n *\n */\nFunction [ function mb_ereg_replace ] {\n @@ /home/fredemmott/systemlib.phpmbstring 288 - 291\n\n - Parameters [4] {\n Parameter #0 [ HH\\mixed \$pattern ]\n Parameter #1 [ HH\\string \$replacement ]\n Parameter #2 [ HH\\string \$str ]\n Parameter #3 [ HH\\mixed or NULL \$option = NULL ]\n }\n}\n"
hphpd> =$x
wire error: a:1:{s:1:"_";O:18:"ReflectionFunction":2:{s:27:"
...(omitted)
hphpd> serialize($x)

Warning: Attempted to serialize unserializable builtin class ReflectionFunction
hpmhpd>
```

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.