Part of #2514
Part of #2514