final class · System

Boxed<T>

public final class Boxed<T>

What an any holds a function value or a pointer in (neither is an object of its own): any a = f; makes one, (func<i32> : i32)a takes the value back out. It shows the value's type.

Kind
final class
Namespace
System
Assembly
System.Core
Access
public, final
Source file
Any.ant

Type parameters

NameConstraints
Tany type

Inheritance

Base classes
Any Boxed<T>

Constructors

new(T Value, str type)
#

Methods

override ToString() : str
#

override

Fields

readonly T Value
#

The function value or pointer.

Private and internal members (1)

readonly str type
#

private

Inherited members (4)

Source

Boxed<T> as Antril, decompiled from its Larva HIR.

System.Boxed.ant
// System.Boxed — System.Core (decompiled from Larva HIR)

into namespace System
{
	/// What an `any` holds a function value or a pointer in (neither is an object of its own): `any a = f;` makes one,
	/// `(func<i32> : i32)a` takes the value back out. It shows the value's type.
	public final class Boxed<T>
	{
		readonly str type;

		public:
			/// The function value or pointer.
			readonly T Value;

			new(T Value, str type)
			{
				this.Value = Value;
				this.type = type;
			}

			override ToString() : str => type;
	}
}
Esc