The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.
use v6-alpha;
class Point;

has $.x is rw;  # instance attributes
has $.y;        # default "is readonly"

method clear () {
    $.x = 0;  # accessible within the class
    $.y = 0;
}