diff --git a/language/types/integer.xml b/language/types/integer.xml index 1a3416fe9a..8592e14b8e 100644 --- a/language/types/integer.xml +++ b/language/types/integer.xml @@ -197,6 +197,12 @@ var_dump(round(25/7)); // float(4) integer with the intval function. + + If a resource is converted to an integer, then + the result will be the unique resource number assigned to the + resource by PHP at runtime. + + See also Type Juggling. diff --git a/language/types/string.xml b/language/types/string.xml index b303f64949..5a2855cc70 100644 --- a/language/types/string.xml +++ b/language/types/string.xml @@ -960,11 +960,13 @@ bool(false) Resources are always converted to strings with the - structure "Resource id #1", where 1 is - the unique number assigned to the resource by PHP at runtime. Do - not rely upon this structure; it is subject to change. To get a - resource's type, use the - get_resource_type function. + structure "Resource id #1", where 1 + is the resource number assigned to the resource by PHP at + runtime. While the exact structure of this string should not be relied on + and is subject to change, it will always be unique for a given resource + within the lifetime of a script being executed (ie a Web request or CLI + process) and won't be reused. To get a resource's type, use + the get_resource_type function.