Commit graph

76 commits

Author SHA1 Message Date
Iain Buclaw
dd2edb247f Synchronize dmd-cxx with gdc-stable 2019-01-05 14:10:15 +01:00
Sebastian Wilzbach
70f06b2357 Remove old, redundant private import access specifier
Very very old versions of D (well into 0.x) had imports public by default,
like C header files. This modernizes the codebase and removes the
redundant `private` access specifier.
This has been done with:

sed "s/private import/import/g" -i **/*.d
2017-07-11 12:28:39 +02:00
Sebastian Wilzbach
61717ecc7d Sort imports 2017-06-12 07:54:38 +02:00
Sebastian Wilzbach
c36f95280c Remove quickIndex for modules with booktables or only one symbol 2017-03-01 03:59:22 +01:00
Sebastian Wilzbach
203755d296 Automatically add spaces to binary operators (>>)
command:

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-23 00:57:47 +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
Jack Stouffer
9d8cb9fda2 Removed uses of the delete keyword from std.mmfile 2016-10-27 16:30:30 +01:00
Atila Neves
46e433b99b Add @system to std.mmfile unit tests 2016-07-01 10:26:08 +02:00
Sebastian Wilzbach
ec47ac4224 Remove the WEB macro in favor of HTTP
replacement: sed 's/\$(WEB/\$(HTTP/g' -i **/*.d
2016-06-16 00:14:51 +02:00
Sebastian Wilzbach
1d34a121e9 apply all-man braces in Phobos
// find common cases
sed -E "s/^(\s*)((if|static if|for|foreach|foreach_reverse|while|unittest|switch|else|version).*)\s*\{$/\1\2\n\1{/" -i **/*.d
// catch else-if
sed -E "s/^(\s*)} (else static if| if|else if|else)(.*)\s*\{$/\1}\n\1\2\3\n\1{/" -i **/*.d
// remove created trailing whitespace
sed -i 's/[ \t]*$//' **/*.d
2016-05-31 13:07:53 +02:00
Sebastian Wilzbach
18b8abf60a remove the deprecated wiki macros 2016-05-27 05:52:23 +02:00
Nikolay Tolstokulakov
eff74ed2a2 netbsd patch 2016-03-11 10:10:47 +06:00
Vladimir Panteleev
290a94243f fix Issue 14995 - std.mmfile incorrectly handles errors in ctor 2015-09-02 01:57:34 +00:00
Vladimir Panteleev
836be856fa fix Issue 14994 - std.mmfile incorrectly handles map failure 2015-09-01 11:31:44 +00:00
Vladimir Panteleev
1fc0fa1fa9 fix Issue 14868 - MmFile destructor seems to corrupt memory 2015-09-01 07:42:27 +00:00
Vladimir Panteleev
2dc53b839a Revert "mmfile.d: MmFile destructor changed not to cal enforce"
This reverts commit 4f3b3f4f1c.

> This fix is incorrect and dangerous. You've removed a potential
> InvalidMemoryOperationError, which is deadly but easy to detect,
> but retained the possibility of closing the file handle of a
> completely unrelated file, if that file handle has since been
> reused. With this change, the bug will always be silent and much
> harder to find the real cause of.
2015-09-01 07:42:22 +00:00
Sergei Degtiarev
4f3b3f4f1c mmfile.d: MmFile destructor changed not to cal enforce
commented code removed
2015-08-11 13:33:01 -04:00
Joakim
3352c90c2e Separate linux kernel, glibc, and bionic APIs where appropriate 2015-05-27 21:54:52 -05:00
k-hara
e7b3d834d7 detab and remove trailing whitespaces 2015-02-10 00:56:40 +09:00
Daniel Murphy
6af3fb5525 Remove implicit conversions from array to bool 2015-01-27 21:55:00 +11:00
Martin Nowak
c855945f46 Merge pull request #2614 from Geod24/fix-license-doc
[DDOC] Usage of WEB macro for License everywhere
2014-10-17 00:16:49 +02:00
Daniel Murphy
af0629ec7c Merge pull request #2337 from joakim-noah/deprecate_std_c
Deprecate std.c.* and move all remaining declarations to core.stdc.*
2014-10-16 01:17:40 +11:00
Geod24
0fb95b8c27 Usage of WEB macro for License everywhere 2014-10-15 11:30:42 +02:00
Joakim
093d636de4 Deprecate std.c.* and move all remaining declarations to core.stdc.* 2014-10-14 09:26:21 -05:00
Vladimir Panteleev
b4afbeaf2d std.mmfile: Fix Windows anonymous mapping creation to conform to MSDN 2014-10-04 14:58:06 +00:00
Vladimir Panteleev
4a97eab1a0 std.mmfile: Improve error handling
Use wenforce instead of (inappropriately) errno.
Switch from if blocks to scope blocks.
2014-10-04 14:50:09 +00:00
k-hara
afbe12f1b1 fix property enforcement 2014-09-06 08:57:15 +09:00
Denis Shelomovskij
ff144b0ae0 Replace most toStringz/toUTF16z/toUTFz usages with tempCString* ones.
Only non-trivial cases left when a refactoring is required to use a temporary buffer.
Also add `nothrow`/`@nogc` attributes.
2014-08-23 17:23:13 +04:00
Joakim
60cfc11a11 Make all tests that create a temporary file in the local directory get the path from one central function, so they can be made to use an absolute path 2014-08-04 23:33:25 -05:00
Adam Saka
afb10ade85 Changed tabs to spaces 2014-07-07 09:57:09 +10:00
Adam Saka
e05a7a1230 Issue 8370 - Fix deprecated message during Linux Phobos build.
This change fixes Linux builds only. Other Posix based OS's will still use the deprecated alias from the Posix module. (This is the same behavior as the garbage collector module.)
2014-07-02 22:51:50 +10:00
Denis Shelomovskij
a81c4127f2 Use Unicode version of CreateFileMapping in std.mmfile.MmFile constructor.
It's a bad style to use ANSI WinAPI function and may cause problems in future.
2014-06-12 17:42:09 +04:00
Ben Grabham
b462d98887 fix Issue 7822 - lseek cast(int)offset should be lseek cast(off_t)offset 2014-05-28 01:32:59 +01:00
Daniel Murphy
13f343334c Remove cases where an array is used in a boolean context 2013-11-27 18:23:07 +11:00
Daniel Murphy
1754eed7f6 Fix cases where goto skips initialization of variables 2013-11-20 00:20:33 +11:00
Johannes Pfau
f989b219cc Get rid of transitional lfs API
Those kind of functions should be placed in druntime,
but the *64 (v) functions as a public interface are actually
deprecated and shouldn't be used anymore.

Druntime takes care that the normal stat, fopen, calls support
large files, if __USE_FILE_OFFSET64 is defined (which is what
the new C API does as well)

Note: It's actually important to use the functions from
core.sys.posix.stdio as the functions in core.stdc.stdio
are not large file aware. This is probably a bug in druntime.
2012-09-30 10:47:40 +02:00
alexrp
adcac57526 Use errno instead of getErrno in Phobos. 2012-07-09 01:26:02 +02:00
Denis Shelomovskij
efc9da711c Remove Windows 3.x and Win9x enforcements from std.mmfile 2012-02-10 14:28:14 +04:00
Denis Shelomovskij
99ab2b6175 Remove __file.d and it's using
* remove `useWfuncs` using
* remove std.__file using
* remove __file.d
* remove variables which have become unnecessary
* remove std.windows.charset import and alias in file.d
2012-02-10 14:27:34 +04:00
Marco Leise
b0009aaa9f Set 'fd' field to 'fildes' from within the Linux constructor that takes a file #. 2012-02-02 08:53:39 +01:00
Walter Bright
f3aa58592f make invariants const-correct 2012-01-29 14:03:39 -08:00
Daniel Green
58f4356ca2 Change version( Win32 ) to version( Windows ) when Win64 would be supported as well. 2012-01-16 22:10:18 -05:00
David Nadlinger
927f879dba Linux build fix, was missing from pull 342. 2011-12-04 21:48:43 +01:00
dsimcha
2c354d14c0 Fix trivial oversight in the enum renaming in std.mmfile. 2011-08-13 23:30:44 -04:00
jmdavis
0105bc93a0 Fixed enum in std.mmfile to follow Phobos naming conventions. 2011-08-13 00:19:32 -07:00
Walter Bright
83f99df573 remove octal literals 2011-04-01 22:34:46 -07:00
Walter Bright
046e1b36db add source links 2011-02-06 15:46:50 -08:00
Don Clugston
84477a5d3e Move Boost copyright declaration from ddoc to normal comment. Fixes ugly ddoc output. 2010-11-24 19:34:47 +00:00
Andrei Alexandrescu
7979116eb4 Replaced std.contracts with std.exception throughout 2010-07-04 22:12:18 +00:00
Masahiro Nakagawa
767b5366c5 bugzilla 4202 Changset 1517 doesn't compile. 2010-05-18 11:35:52 +00:00