phpday 2027 - Call for Papers

Error::__clone

(PHP 7, PHP 8)

Error::__clone — Clone the error

Descrizione

private function Error::__clone(): void

Errors do not support cloning; this method exists only to prevent it.

Avviso

Errors cannot be cloned, whether they are instances of Error or of a subclass. Attempting to clone an error throws an Error, which may be caught.

Elenco dei parametri

Questa funzione non ha parametri.

Valori restituiti

Nessun valore viene restituito.

Errori/Eccezioni

Attempting to clone an error throws an Error with the following message: Trying to clone an uncloneable object of class ClassName.

Log delle modifiche

Versione Descrizione
8.1.0 Error::__clone() is no longer final.

User Contributed Notes

There are no user contributed notes for this page.
Adding new notes is disabled. Please see the links in the Found A Problem? section.
To Top