<?php
/***************************************************************************
- * Copyright (C) 2003-2010 Polytechnique.org *
+ * Copyright (C) 2003-2011 Polytechnique.org *
* http://opensource.polytechnique.org/ *
* *
* This program is free software; you can redistribute it and/or modify *
}
}
+function pl_assert_cb($file, $line, $message)
+{
+ Platal::assert(false, "Assertion failed at $file:$line with message: $message");
+}
+
set_error_handler('pl_error_handler', E_ALL | E_STRICT);
+assert_options(ASSERT_CALLBACK, 'pl_assert_cb');
+assert_options(ASSERT_WARNING, false);
if (php_sapi_name() == 'cli') {
register_shutdown_function('pl_print_errors');
}