Part of #114
Part of #114