Development · Native API migration preview · Coverage validation in progress Published release →

API Browser

Method

Clone

abstract virtual func Clone() -> Self

Declaring type: Clonable
Module: System
Assembly: System.Runtime.dll
Source file: Clonable.rvn

Defined by Clonable.Clone · Required implementation (no default).

Interface implementation: Required implementation (no default).

Returns a clone of the implementing Self type.

Return value

Self

A value of the concrete implementing type, according to its documented copying contract.

Remarks

Implementations must document copy depth, shared references and resource ownership. Generic callers retain T through a Clonable bound. The native borrowed receiver preserves value storage or loads a class reference without boxing; null class receivers fault. The current application importer admits direct class/struct implementations and explicit derived class mappings. Inherited Self stays anchored to the conformance-declaring base class; derived generic Self bounds require redeclaration with an exact derived result. Virtual overrides preserve the base result contract.