#33203 [Csd->Opn]: Document limitations of var_export()

From: Date: Mon, 17 Oct 2005 08:55:14 +0000
Subject: #33203 [Csd->Opn]: Document limitations of var_export()
References: 1  Groups: php.doc 
Request: Send a blank email to phpdoc+get-969370612@lists.php.net to get a copy of this message
ID: 33203 Updated by: derick@php.net Reported By: mfischer@php.net -Status: Closed +Status: Open Bug Type: Documentation problem PHP Version: Irrelevant New Comment: I am reopening this as I found a way to do this for classes now. Previous Comments: ------------------------------------------------------------------------ [2005-06-01 11:15:47] vrana@php.net This bug has been fixed in the documentation's XML sources. Since the online and downloadable versions of the documentation need some time to get updated, we would like to ask you to be a bit patient. Thank you for the report, and for helping us make our documentation better. "Variables of type resource and arrays or objects containing objects couldn't be exported by this function." ------------------------------------------------------------------------ [2005-05-31 16:02:46] mfischer@php.net According to http://bugs.php.net/bug.php?id=29361 it also doesn't supported objects containing references to other objects. This should be documented too. ------------------------------------------------------------------------ [2005-05-31 16:01:37] mfischer@php.net Description: ------------ A limitation of var_export() is not documented. It does not support resources. The manual says "generated valid PHP code" which is fine. But it should be noted that resources are not supported, i.e. they're not reflected as resources in var_export anymore. Reproduce code: --------------- $ php -r '$f = fopen("/", "r"); var_export($f);' NULL ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=33203&edit=1

« previous php.doc (#969370612) next »