numbas / Numbas

A completely browser-based e-assessment/e-learning system, with an emphasis on mathematics
http://www.numbas.org.uk
Apache License 2.0
200 stars 118 forks source link

cast from list to vector no longer works in some cases (not true - it is list concatenation that is the problem) #131

Closed BillFoster closed 12 years ago

BillFoster commented 12 years ago

Get error message if cast a1 to b in git://gist.github.com/1819215.git but not for casting L to V

TypeError: Cannot read property ‘length’ of undefined at Object.evaluate (file:///D:/Numbas/output/mas1342cba1generic/scripts/jme.js:443:28) at [object Object].evaluate (file:///D:/Numbas/output/mas1342cba1generic/scripts/jme.js:1587:18) at Object.evaluate (file:///D:/Numbas/output/mas1342cba1generic/scripts/jme.js:460:18) at compute (file:///D:/Numbas/output/mas1342cba1generic/scripts/jme-variables.js:171:26) at Object.makeVariables (file:///D:/Numbas/output/mas1342cba1generic/scripts/jme-variables.js:176:4) at file:///D:/Numbas/output/mas1342cba1generic/scripts/question.js:59:39 at file:///D:/Numbas/output/mas1342cba1generic/scripts/schedule.js:42:7 at file:///D:/Numbas/output/mas1342cba1generic/scripts/schedule.js:63:4

BillFoster commented 12 years ago

In fact it is the operations a+1 and [0]+a it is objecting to, not the casting!!!