develooper Front page | perl.perl6.users | Postings from December 2019

rmdir question

Thread Next
ToddAndMargo via perl6-users
December 3, 2019 02:37
rmdir question
Message ID:
Hi All,

 From the manual page of rmdir:

       sub    rmdir(*@dirs --> List:D)
       method rmdir(IO::Path:D: --> True)

Does *@dirs mean I can give it multiple directories
as an array?

What does  "--> List:D" give me back?  An array
of Booleans as to which directories successfully removed?
And what is a "List:D?" anyway?

      ...throws an exception of type X::IO::Rmdir if
      the directory cannot be removed

Does this crash the program or just return a "false"?
Does it tell me what went wrong, as in "so and so" has
"such and such" file(s) open and locked?

To delete non-empty directory, see rmtree in File::Directory::Tree module.

Seems to me I should not have to import a module for
this.  Most rmdir command have a "parents" flag.  Am
I missing something?

Many thanks,

A computer without Microsoft is like
a chocolate cake without the mustard

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About