Skip to content

Commit

Permalink
move sections to composite types pages
Browse files Browse the repository at this point in the history
  • Loading branch information
turbolent committed Oct 4, 2022
1 parent 2f04fa3 commit 3ee6db9
Showing 1 changed file with 0 additions and 24 deletions.
24 changes: 0 additions & 24 deletions docs/language/resources.mdx
Expand Up @@ -606,27 +606,3 @@ Otherwise the field is `nil`.
The field's value changes when the resource is moved from outside account storage
into account storage, when it is moved from the storage of one account
to the storage of another account, and when it is moved out of account storage.

## Unbound References / Nulls

There is **no** support for `null`.

## Inheritance and Abstract Types

There is **no** support for inheritance.
Inheritance is a feature common in other programming languages,
that allows including the fields and functions of one type in another type.

Instead, follow the "composition over inheritance" principle,
the idea of composing functionality from multiple individual parts,
rather than building an inheritance tree.

Furthermore, there is also **no** support for abstract types.
An abstract type is a feature common in other programming languages,
that prevents creating values of the type and only
allows the creation of values of a subtype.
In addition, abstract types may declare functions,
but omit the implementation of them
and instead require subtypes to implement them.

Instead, consider using [interfaces](interfaces).

0 comments on commit 3ee6db9

Please sign in to comment.