use deftype for state
do not use extra protocols
do not return values from callbacks