Fix #1414 by having more descriptive error thrown by AssignValue

Fixes #1414

Tiny little ops fix :)