Provide assert as an external method.

Removed the internal assert implementation from the engine
and provide externally an assert function via api calls.

JerryScript-DCO-1.0-Signed-off-by: Peter Gal pgal.u-szeged@partner.samsung.com
This commit is contained in:
Peter Gal
2015-06-17 17:04:13 +02:00
parent 61ab205130
commit 77b01a6473
3 changed files with 49 additions and 35 deletions
+5
View File
@@ -19,6 +19,11 @@
#include "test-common.h"
const char *test_source = (
"function assert (arg) { "
" if (!arg) { "
" throw Error('Assert failed');"
" } "
"} "
"this.t = 1; "
"function f () { "
"return this.t; "