Clear the most recent error

# error_clear_last

(PHP 7)

error_clear_last — Clear the most recent error

### Descrierea

error_clear_last ( void ) : void

### Valorile întoarse

Clears the most recent errors, making it unable to be retrieved with error_get_last().

### Exemple

Example #1 An error_clear_last() example

`<?php
var_dump(error_get_last());
error_clear_last();
var_dump(error_get_last());
@$a = $b;
var_dump(error_get_last());
error_clear_last();
var_dump(error_get_last());
?>`

Exemplul de mai sus va afișa ceva similar cu:

    NULL
    NULL
    array(4) {
      ["type"]=>
      int(8)
      ["message"]=>
      string(21) "Undefined variable: b"
      ["file"]=>
      string(9) "%s"
      ["line"]=>
      int(6)
    }
    NULL

### A se vedea și

- Error constants