Skip to content

Commit

Permalink
[docs] Improve searchability of "Methods" section (apple#625)
Browse files Browse the repository at this point in the history
  • Loading branch information
HT154 authored Aug 19, 2024
1 parent ef0433a commit e5b7e04
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion docs/modules/language-reference/pages/index.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -2006,7 +2006,8 @@ pigeon: ParentBird = new {
[[methods]]
== Methods

Modules and classes can define methods.
Pkl methods can be defined on classes and modules using the `function` keyword.
Methods may access properties of their containing type.
Submodules and subclasses can override them.

Like Java and most other object-oriented languages, Pkl uses _single dispatch_ -- methods are dynamically dispatched based on the receiver's runtime type.
Expand Down

0 comments on commit e5b7e04

Please sign in to comment.