add isDefined (#8)