HPlogo System Debug Reference Manual > Chapter 11 System Debug Standard Functions

func typeof

MPE documents

Complete PDF
Table of Contents
Index

E0201 Edition 4 ♥
E0300 Edition 3
E0692 Edition 3

Returns the type of an evaluated expression as a string.

Syntax



   typeof (expr)  

Formal Declaration



   typeof:str (expr:any) 

Parameters


expr

Any expression for which the resultant type is desired.

Examples



   $nmdebug > wl typeof(1+2+3)
   U16

   $nmdebug > wl typeof(#65535)
   U16

   $nmdebug > wl typeof(#65535+1)
   U32

   $nmdebug > wl typeof (-1)
   S16

   $nmdebug > wl typeof ($1ffff)
   S32

   $nmdebug > wl typeof(true)
   BOOL

   $nmdebug > wl typeof("Nellie of Meadow Farm")
   STR

   $nmdebug > wl typeof(typeof(123))
   STR

   $nmdebug > wl typeof(pc)
   SYS

   $nmdebug > wl typeof(cmpc)
   GRP

   $nmdebug > wl typeof(cmtonmnode(cmpc))
   TRANS

   $nmdebug > wl typeof(a.c00024c8)
   LPTR

   $nmdebug > wl typeof(pib(pin))
   SPTR

Limitations, Restrictions


none




func trans


func u16