proc
derived_from(child, parent)
return (child in typesof(parent)) ? 1 : 0
Two things unnecessary with this:
- "A in B" returns a boolean value already, so the ternary operation is redundant.
- This proc already exist as the built-in ispath(child, parent).