Commit graph

507 commits

Author SHA1 Message Date
Jonathan M Davis
fc86ca916e Fix issue 17962: dirEntries is truncating Unicode file names. 2017-11-05 18:56:32 -07:00
Alexandru Jercaianu
d30cda8feb impl is initialized only in constructor 2017-10-07 15:39:37 +03:00
Alexandru Jercaianu
7f6ce8026f added safe in the stddoc block 2017-10-07 12:41:08 +03:00
Alexandru Jercaianu
b7f8edd630 safe at toplevel; replaced strlen with countUntil 2017-10-07 10:57:56 +03:00
Alexandru Jercaianu
daa79a5b03 removed unused lstatbuf 2017-10-05 13:23:50 +03:00
Alexandru Jercaianu
5e88b67808 minor code refactoring 2017-10-05 13:20:39 +03:00
Alexandru Jercaianu
0ff1cfe045 Safe for windows 2017-10-01 11:38:58 +03:00
Alexandru Jercaianu
aac8e8d7d9 DirIterator is safe 2017-09-30 19:57:30 +03:00
wolframw
0a434259c0 Fix documentation for std.file
Corrected typos and added $(D) where necessary. Added underscores to
non-identifier tokens which weren't properly prefixed (and were
therefore wrongly hightlighted in the docs).
2017-07-25 21:57:12 +02:00
Sebastian Wilzbach
cf7766c1a9 Make std.file examples runnable 2017-07-09 16:22:53 +02:00
Vladimir Panteleev
2e6c52d02f
std.file: Unify dirEntries overloads' documentation 2017-07-07 17:33:29 +00:00
Vladimir Panteleev
4697a127c2
Update a missed dirEntries overload (fixup for #5569) 2017-07-07 16:31:57 +00:00
Vladimir Panteleev
efd740e551
Improve documentation of std.file.SpanMode (issue 8680)
This clarifies the terminology used for describing the iteration order
of dirEntries, as the current terminology has been found misleading.
2017-07-07 15:39:28 +00:00
Vladimir Panteleev
657339069c Fix broken links 2017-07-06 19:15:31 +02:00
Sebastian Wilzbach
d8959320e0 Fix deprecations on Windows 2017-07-06 01:01:52 +02:00
Roman Chistokhodov
dc7f802605 Add errnoString to remove code duplication from some modules 2017-07-01 02:34:49 +03:00
Jack Stouffer
20d40a954c Switched package-wide datetime imports to new sub-packages 2017-06-30 13:51:53 -04:00
Sebastian Wilzbach
d2c5c53ab7 Fix REF links in std.file.slurp 2017-06-24 04:50:11 +02:00
Vladimir Panteleev
d0b9555a06
Revert "Sort selective imports"
This reverts commit 998ad51fd7.
2017-06-13 17:51:52 +00:00
Sebastian Wilzbach
2070d867dd Sort multiple packages within one line 2017-06-12 08:18:25 +02:00
Sebastian Wilzbach
998ad51fd7 Sort selective imports 2017-06-12 08:12:09 +02:00
Sebastian Wilzbach
61717ecc7d Sort imports 2017-06-12 07:54:38 +02:00
Steven Schveighoffer
fabf19affc Defer addition of template until we need it for ranges. 2017-05-17 08:32:43 -04:00
Sebastian Wilzbach
e50531d921 Fix issue 17394 - mkdirRecurse isn't @safe 2017-05-13 13:34:07 +02:00
Christian Köstlin
6fa5e0e969 Fixed some typos 2017-03-14 23:13:47 +01:00
Adam D. Ruppe
929201370c Document undocumented overloads that take string
When looking at the signatures of std.file, it looks like
it only takes input ranges and specifically disallows strings.
The text of most functions say it can take strings, but the
proper overload isn't displayed at all.

This gave me a moment of confusion earlier today, so I decided to
just fix it with a bunch of little dittos. Now, the string overloads
should appear right with the non-string overloads.
2017-03-09 11:10:01 -05:00
Sebastian Wilzbach
56d78c0e5c [BOOKTABLES]: Add BOOKTABLE to std.file 2017-03-01 08:21:35 +01:00
Andrei Alexandrescu
30724e67d9 Merge pull request #5166 from wilzbach/dscanner-unittest-safe-or-system
Dscanner: let unittest be @safe or @system
2017-02-22 14:44:08 -05:00
Sebastian Wilzbach
a36cec8686 DScanner: automatially set all unattributed unittests to @safe or @system 2017-02-22 05:42:04 +01:00
Sebastian Wilzbach
425ab667a3 Automatically set the range style from a..b -> a .. b
Commands:

sed -E "s/([[:alnum:]])[.][.]([[:alnum:]])/\1 .. \2/g" -i **/*.d
sed -E "s/([[:alnum:]])[.][.] ([[:alnum:]])/\1 .. \2/g" -i **/*.d
sed -E "s/([[:alnum:]]) [.][.]([[:alnum:]])/\1 .. \2/g" -i **/*.d
2017-02-22 05:37:31 +01:00
Sebastian Wilzbach
805c720595 Unify Phobos by ensuring there's always a space after cast(...)
Command:

sed -E 's/([^"])cast\(([^)]*?)\)([[:alnum:]])/\1cast(\2) \3/g' -i **/*.d
2017-02-21 16:40:20 +01:00
Sebastian Wilzbach
5521541032 Unify assert style to have no spaces between the first brace
Application of:

sed -E "s/assert +\(/assert(/" -i **/*.d
2017-02-21 15:27:15 +01:00
Nick Sabalausky
5a2da77fbc std.file: Document that write/append create the file if it doesn't exist. 2017-02-20 13:51:27 -05:00
Sebastian Wilzbach
87dec58a41 DStyle: Constraints on declarations should have the same indentation level 2017-02-17 07:36:23 +01:00
Jack Stouffer
da65768451 Add checks for infinite ranges in many range function signitures 2017-02-14 21:59:12 -05:00
Jack Stouffer
360a42ec05 Add checks for infinite ranges in many range function signitures 2017-02-14 14:19:04 -05:00
The Dlang Bot
c6d33505dc Merge pull request #5049 from Burgos/fix-17102
fix issue 17102 - Don't pass null to strlen in std.file.cenforce
merged-on-behalf-of: Jack Stouffer <jack@jackstouffer.com>
2017-01-21 18:48:11 +01:00
Nemanja Boric
e80d3b5745 Fix Issue 17102: std.write.file generates a segmentation fault when the
file name is a string with a default value

While trying to build the file name for exception
from 0terminated namez, don't pass null to strlen
2017-01-21 18:07:17 +01:00
Sebastian Wilzbach
18ecb6b72c Make more modules publicly runnable on dlang.org 2017-01-06 23:29:55 +01:00
Ryan Roden-Corrent
0a685f1daf Ensure std.file.exists(StringEnum.name) compiles.
A string-typed enum passes isSomeString but not isConvertibleToString.
Because isConvertibleToString is used as a template constraint for
std.file.exists, it could not be passed a string-typed enum.

Resolves #16573.
2016-10-30 18:57:11 -04:00
Jack Stouffer
9c4368f52c Removed uses of the delete keyword from std.file 2016-10-26 08:59:44 +01:00
Joakim
b4061155cd Fix Issue 16571 - Unittests should not list /tmp/ recursively 2016-10-04 16:26:27 +05:30
Andrei Alexandrescu
2f8e693e5d Merge pull request #4814 from e-y-e/fixflags
[trivial] [large diff] Update uses of Flag to use the Yes/No structs.
2016-09-30 18:25:44 -04:00
e-y-e
befa0bfb6e Updated Flag uses to Yes/No structs 2016-09-29 14:45:20 +01:00
Jack Stouffer
b3a8f49ca0 Added some const to varibles that aren't modified 2016-09-23 12:41:19 +01:00
Walter Bright
cc3fc19744 file.d: fix unsafe use of .ptr 2016-07-25 21:38:08 -07:00
Jack Stouffer
38fd55eb65 Removed package wide std.algorithm imports from std.file 2016-07-18 09:50:18 -04:00
Jack Stouffer
6b02d380b1 Removed unused variables from std.file 2016-07-12 09:51:35 -04:00
Walter Bright
782e5399ea Merge pull request #4455 from JackStouffer/file
Remove some global imports from std.file
2016-07-08 20:26:52 -07:00
Atila Neves
aad03b2829 Add @system and @safe to std.file unit tests 2016-07-08 16:31:17 +02:00