Quaternion type: Difference between revisions
Content deleted Content added
→{{header|Perl 6}}: bless does not take * as default candidate anymore |
|||
Line 3,492: | Line 3,492: | ||
multi method new ( Real $r, Real $i, Real $j, Real $k ) { |
multi method new ( Real $r, Real $i, Real $j, Real $k ) { |
||
self.bless: |
self.bless: :$r, :$i, :$j, :$k; |
||
} |
} |
||
method Str ( ) { "$.r + {$.i}i + {$.j}j + {$.k}k" } |
method Str ( ) { "$.r + {$.i}i + {$.j}j + {$.k}k" } |