[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-patch-tracker] [patch #8119] Allow variable tolerance and improv
From: |
Dan Sebald |
Subject: |
[Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script |
Date: |
Wed, 14 Aug 2013 22:05:29 +0000 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:18.0) Gecko/20100101 Firefox/18.0 SeaMonkey/2.15 |
Follow-up Comment #23, patch #8119 (project octave):
OK, thanks.
I double-checked some things and the call depth mod isn't quite right. (The
problem with "test assert" is that though it appropriately fails in the right
location, it is hard to tell whether it is failing in the right way.) The
call_depth starts at zero and does an "if (call_depth > 0)" with the
consequence that an error() always occurs. Try:
x = {[3], [1,2,3]; 100+100*eps, "dog"};
y = x; y(1,1) = [2]; y(1,2) = [0, 2, 3]; y(2,1) = 101; y(2,2) = "cat";
assert (x, y)
With the attached change, call_depth is always incremented and always
decremented at the end (otherwise subsequent calls to the function will
fail).
(file #28844)
_______________________________________________________
Additional Item Attachment:
File name: octave-assert_call_depth-2013aug14.patch Size:1 KB
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/patch/?8119>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, (continued)
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Dan Sebald, 2013/08/07
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Dan Sebald, 2013/08/07
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Rik, 2013/08/07
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Dan Sebald, 2013/08/07
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Rik, 2013/08/08
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Dan Sebald, 2013/08/11
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Dan Sebald, 2013/08/12
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Dan Sebald, 2013/08/12
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Dan Sebald, 2013/08/12
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Rik, 2013/08/14
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script,
Dan Sebald <=
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Rik, 2013/08/15
- [Octave-patch-tracker] [patch #8119] Allow variable tolerance and improve error messages for assert.m script, Dan Sebald, 2013/08/15