> For the complete documentation index, see [llms.txt](https://trizen.gitbook.io/perl6-rosettacode/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://trizen.gitbook.io/perl6-rosettacode/programming_tasks/i/inheritance/single.md).

# Single

```perl
class Animal {}
class Dog is Animal {}
class Cat is Animal {}
class Lab is Dog {}
class Collie is Dog {}

say Collie.^parents;     # undefined type object
say Collie.new.^parents; # instantiated object
```

#### Output:

```
((Dog) (Animal))
((Dog) (Animal))
```

The `.^parents` notation indicates a method call to the object's metaobject rather than to the object itself.
