Permalink
Browse files

document Method

  • Loading branch information...
1 parent 007159d commit 106a1f75882a3226d82957645c4a635b73c775bd @moritz moritz committed Aug 25, 2012
Showing with 14 additions and 0 deletions.
  1. +14 −0 lib/Method.pod
View
@@ -0,0 +1,14 @@
+=begin pod
+
+=TITLE class Method
+
+ class Method is Routine { }
+
+A type for methods. To create a method, use the C<method> keyword:
+
+ my $m = method ($invocant: $param) {
+ say "$invocant: '$param'";
+ }
+ "greeting".$m("hello"); # greeting: 'hello'
+
+=end pod

0 comments on commit 106a1f7

Please sign in to comment.