Implementing des is_weak to get rid of a dependency