octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Matlab compatibility of assert


From: Julien Bect
Subject: Re: Matlab compatibility of assert
Date: Tue, 24 Sep 2013 18:03:41 +0200
User-agent: Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.0

On 24/09/2013 17:50, John W. Eaton wrote:
Maybe we should implement the Matlab behavior in assert and use
test_assert or tassert, or something else for the Octave assert
functionality that we use in the test suite?  Then we could easily
make assert a built-in function and it would be somewhat faster too,
solving the initial performance concern.

We could leave the !%assert syntax alone, but have it call the new
test_assert function.

The built-in assert function could test for the Matlab style case and
perform that action, otherwise warn about deprecated usage and call
the new test_assert function.

I like this solution.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]