For the complete Mojo documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /docs/manual/basics.md).
is_trivially_deletable
def is_trivially_deletable[T: AnyType]() -> Bool
Returns whether T has a trivial destructor.
A destructor is trivial when the compiler generates it and all of T's
fields are themselves trivially destructible. In practice this means
__deinit__ is a no-op. A non-Deinitable (linear) type returns False
Parameters:
- T (
AnyType): The type to check.
Returns:
Bool: True if T has a trivial destructor.