This closes #4076