Skip to content

Commit

Permalink
Merge 2019-02 LWG Motion 12
Browse files Browse the repository at this point in the history
P1164R1 Make create_directory() Intuitive

Fixes #2703.
  • Loading branch information
zygoloid committed Mar 14, 2019
2 parents c2dac40 + a911187 commit 9be92b8
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions source/iostreams.tex
Original file line number Diff line number Diff line change
Expand Up @@ -14742,8 +14742,6 @@
\returns \tcode{true} if a new directory was created
for the directory \tcode{p} resolves to,
otherwise \tcode{false}.
The signature with argument \tcode{ec}
returns \tcode{false} if an error occurs.

\pnum
\throws As specified in~\ref{fs.err.report}.
Expand All @@ -14765,13 +14763,13 @@
\begin{itemdescr}
\pnum
\effects Creates the directory \tcode{p} resolves to,
as if by POSIX \tcode{mkdir()} with a second argument of
as if by POSIX \tcode{mkdir} with a second argument of
\tcode{static_cast<int>(perms::all)}.
Creation failure because \tcode{p} already exists is not an error.
If \tcode{mkdir} fails because \tcode{p} resolves to an existing directory,
no error is reported. Otherwise on failure an error is reported.

\pnum
\returns \tcode{true} if a new directory was created, otherwise \tcode{false}.
The signature with argument \tcode{ec} returns \tcode{false} if an error occurs.

\pnum
\throws As specified in~\ref{fs.err.report}.
Expand All @@ -14789,7 +14787,8 @@
directory \tcode{p} resolves to, with
attributes copied from directory \tcode{existing_p}. The set of attributes
copied is operating system dependent.
Creation failure because \tcode{p} already exists is not an error.
If \tcode{mkdir} fails because \tcode{p} resolves to an existing directory,
no error is reported. Otherwise on failure an error is reported.
\begin{note} For POSIX-based operating systems, the
attributes are those copied by native API \tcode{stat(existing_p.c_str(), \&attributes_stat)}
followed by \tcode{mkdir(p.c_str(), attributes_stat.st_mode)}. For
Expand All @@ -14798,8 +14797,9 @@
\end{note}

\pnum
\returns \tcode{true} if a new directory was created, otherwise \tcode{false}.
The signature with argument \tcode{ec} returns \tcode{false} if an error occurs.
\returns \tcode{true} if a new directory was created
with attributes copied from directory \tcode{existing_p},
otherwise \tcode{false}.

\pnum
\throws As specified in~\ref{fs.err.report}.
Expand Down

0 comments on commit 9be92b8

Please sign in to comment.