Added typeid and assert

Signed-off-by: ysgard <ysgard@gmail.com>