get_resource_type()
function get_resource_type(resource $resource): string
Returns the type of a resource.
Parameters:
$resource(resource)
Returns: string
Availability
- Compiled (AOT): supported by the Elephc code generator.
eval()(magician interpreter): supported — declarative interpreter builtin (crates/elephc-magician/src/interpreter/builtins/symbols/get_resource_type.rs).
No examples yet — check examples/ and showcases/ for usage patterns.
Internals
For how get_resource_type is implemented in the compiler, see the internals page.