Remove __free_impl
Formatting
Cleanup; abstraction
Remove num dependency
Remove allow(dead_code) attribute