public static function error($severity, $message, $file, $line){

		// Respect the "@" error suppression operator

		if(error_reporting() == 0) return;

		elseif(error_reporting() && $severity){

			$ErrorException = new PHPErrorException(
				$message, 0, $severity, $file, $line);

			// If we're in an assert()-chain, *immediately* terminate execution

			if(assert_options(ASSERT_ACTIVE)){

				foreach($ErrorException->getStackTrace() as $element){

					if(isset($element['function']) &&
						$element['function'] == 'assert'){

						self::exception($ErrorException);
					}
				}
			}

			$recoverable = [
				E_WARNING,
				E_NOTICE,
				E_USER_WARNING,
				E_USER_NOTICE,
				E_STRICT,
				E_DEPRECATED,
				E_USER_DEPRECATED
			];

			// Only for non-fatal errors

			if(in_array($severity, $recoverable)){

				return;
			}

			throw $ErrorException;
		}
	}