Delete duplicate code in core/main

The `core/main` namespaces contains some duplicated defs. This commit deletes them.