Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Allow "foo".IO.open/mkdir if "foo" doesn't exist
  • Loading branch information
lizmat committed Nov 29, 2014
1 parent 873e88a commit fd1ee99
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/core/IOU.pm
Expand Up @@ -20,6 +20,9 @@ my class IOU {

method IO(IOU:D:) { $!that // self }

method open(|c) { open($!abspath,|c) }
method mkdir(|c) { mkdir($!abspath,|c) }

multi method Str(IOU:D:) { $!this }
multi method gist(IOU:D:) { qq|"$!this".IO| }
multi method perl(IOU:D:) { "q|$!this|.IO" }
Expand Down

0 comments on commit fd1ee99

Please sign in to comment.