Andrei Alexandrescu
cae6379750
Fix Issue 21249 - clamp() is not stable and is not constrained
2020-09-16 01:20:51 +02:00
Nathan Sashihara
9351e91fe4
Reduce trait template instantiation in std.utf
2020-09-15 13:22:09 +02:00
Nathan Sashihara
aa16e2d99a
Streamline std.traits.AliasThisTypeOf
...
Faster and uses less memory.
2020-09-14 05:35:35 +02:00
Paul Backus
33b1c17540
Fix issue 21237: isLvalueAssignable and isRvalueAssignable should be public
2020-09-12 14:03:14 +02:00
Nathan Sashihara
2f67646b16
Slightly decrease trait template cascades
2020-09-12 12:28:43 +02:00
The Dlang Bot
56b1919e9b
Merge pull request #7623 from MartinNowak/merge_stable
...
merge stable
merged-on-behalf-of: Nathan Sashihara <n8sh@users.noreply.github.com>
2020-09-10 14:58:26 +02:00
H. S. Teoh
34a14509d2
std.experimental.checkedint should support chain assignment.
...
Cf. bug #21169 .
2020-09-10 06:06:01 +02:00
Martin Nowak
498b4b97d6
Merge remote-tracking branch 'upstream/master' into stable
...
Conflicts:
posix.mak
2020-09-09 10:18:21 +02:00
Andrei Alexandrescu
f97c2c05be
Provide float and double versions of fmin and fmax. Improve docs. ( #7604 )
...
Provide float and double versions of fmin and fmax. Improve docs.
merged-on-behalf-of: Andrei Alexandrescu <andralex@users.noreply.github.com>
2020-09-09 07:13:00 +02:00
aG0aep6G
77b4dbbd36
tighten up other imports
...
These don't affect the import graph.
2020-09-08 14:00:11 +02:00
aG0aep6G
3fcf905408
remove unnecessary imports
...
Pulling a single thread out of the hairball of imports that is Phobos.
2020-09-08 14:00:04 +02:00
Geod24
35016ff42d
std.traits: Adapt unittest to pass with -preview=in
2020-08-31 05:32:26 +02:00
Geod24
4d01cacfb4
Fix 21210: std.traits : isAssignable false positive on disabled copy struct
...
`isAssignable` would previously return `true` for non-copyable types,
even though code that tried to use an lvalue would not compile.
This behavior was originally found when implementing `-preview=in`.
With the new -preview=in check, the const-folding seemed to be a bit
too aggressive when an rvalue is passed, meaning that the check might
fail (probably due to the code that initialize the temporary).
2020-08-31 03:13:56 +02:00
Sebastian Wilzbach
1af4e48c4e
Revert "std.traits: Adapt unittest to pass with -preview=in
( #7609 )"
...
This reverts commit aca1e1208f
.
2020-08-30 11:07:05 +02:00
Mathias LANG
aca1e1208f
std.traits: Adapt unittest to pass with -preview=in
( #7609 )
...
* std.traits: Use delegates within some __traits(compiles) check to avoid constfold
With the new -preview=in check, the const-folding seems to be a bit
too aggressive when an rvalue is passed, meaning that the check might
fail (probably due to the code that initialize the temporary).
To avoid this issue, we simply wrap the assignment in a lambda that
will not be called, as there is no downside to that change.
* std.traits: Adapt unittest to pass with `-preview=in`
2020-08-29 19:42:12 +08:00
Andrei Alexandrescu
6194b17295
Fix Issue 21191 - min should be stable: when in doubt, return the first argument
2020-08-28 08:19:40 +02:00
Geod24
691847c61b
std.typecons : AutoImplement: Handle 'in' storage class
2020-08-28 04:27:48 +02:00
Nathan Sashihara
4edc8c8922
Remove an unnecessary allocation from BigInt powmod
2020-08-27 23:59:09 +02:00
Nathan Sashihara
a3c3ea74e3
Fix Issue 21201 - let std.uuid.parseUUID accept input ranges whose elements are char or wchar, not just dchar
...
All characters of interest to std.uuid.parseUUID are ASCII so there is
no reason it cannot work on a range of chars or wchars.
2020-08-27 16:47:53 +02:00
Mathis Beer
4b269a86f2
Fix issue 21199: call unaryFun!fun
in Nullable.apply
to support shortcut string expressions as parameter.
2020-08-26 15:01:04 +02:00
Walter Bright
43c7c32694
fix Issue 21182 - asm code is missing int ptr and so defaults to byte op
2020-08-22 13:46:07 +02:00
MoonlightSentinel
255f9496d1
Fix Issue 21183 - schwartzSort does not strip const
...
Fixed by using the unqualified type if possible
2020-08-21 15:06:11 +02:00
Walter Bright
bf258e56f2
structure SSSE3 array of constants
2020-08-18 07:32:49 +02:00
Nathan Sashihara
99e390486c
Reduce the number of isAggregateType!T checks
...
Some are redundant. Others can be replaced by cheaper traits checks.
2020-08-18 03:50:12 +02:00
FeepingCreature
1f1a80d0a0
Fix issue 21129: Make OnlyResult
store the actual types passed to it as a tuple, instead of a static array of CommonType. ( #7584 )
...
Remove the unittest that verifies that `OnlyResult` doesn't depend on argument order - since it now does.
Add unittest for issue 21129.
2020-08-17 13:02:05 -04:00
Steven Schveighoffer
17ae8fc9be
Make it so std.utf can be tested with no autodecoding.
2020-08-17 06:53:34 +02:00
Geod24
33a713ec65
Change Socket constructor to accept its parameter by const scope
...
This is the only occurence in Phobos where 'in' would get 'ref' applied.
Changing this ensures that users can use '-preview=in' in their code.
2020-08-16 11:12:40 +02:00
Geod24
e190083c3d
UUID: Replace 'in ref' overloads with 'const scope ref'
...
'in' and 'in ref' overloads will conflict in the future if dlang/dmd#11000 is accepted.
Even if not, 'in' currently means something different based on a switch,
however the intention of this code is obviously the full 'const scope'.
In the some places, 'scope' was omitted as it is meaningless on value types.
2020-08-15 13:18:42 +02:00
canopyofstars
90c62c6c4e
Fix issue 7033: File.rawWrite is slow on Windows ( #7590 )
...
Fix issue 7033: File.rawWrite is slow on Windows
merged-on-behalf-of: Steven Schveighoffer <schveiguy@users.noreply.github.com>
2020-08-15 12:07:38 +02:00
Martin Kinkelin
1e15cf6e0d
std.math: Avoid ldexp calls with constant exponents
...
Quoting from https://en.cppreference.com/w/cpp/numeric/math/ldexp :
> On many implementations, std::ldexp is less efficient than
> multiplication or division by a power of two using arithmetic
> operators.
2020-08-15 02:07:39 +02:00
Martin Kinkelin
a76200dd17
std.math: Enable proper single- and double-precision ldexp overloads
...
As the according intrinsics have recently been added to core.math.
Also move `pragma(inline, true)` out of the function as required for LDC
(and non-templated functions, not getting their body analyzed).
2020-08-15 02:00:58 +02:00
Martin Kinkelin
4d3ba080b7
Prepare for properly parsed float/double literals ( #7591 )
...
This fixes failing unittests with dlang/dmd#11387 on Linux x64 by
appending a L suffix to (some) literals, to keep full `real` parsing
precision (instead of double precision).
2020-08-14 21:06:56 +08:00
Nils Lankila
e36b5aaba0
fix issue 21148, possible failure of CI when testing nano precision of file time stamps ( #7589 )
...
fix issue 21148, possible failure of CI when testing nano precision of file time stamps
merged-on-behalf-of: Nicholas Wilson <thewilsonator@users.noreply.github.com>
2020-08-13 10:12:08 +02:00
Vladimir Panteleev
90261c1e19
Fix Issue 20984 - Heisenbug: FreeBSD64 Phobos random test suite failure in std/process
2020-08-11 19:40:59 +02:00
The Dlang Bot
836952dbe9
Merge pull request #7588 from bachmeil/patch-3
...
Update random.d
merged-on-behalf-of: Sebastian Wilzbach <sebi.wilzbach@gmail.com>
2020-08-10 21:54:20 +02:00
Vladimir Panteleev
e2fc53f405
Fix Issue 20765 - Can't run processes with relative paths when specifying a working directory
...
Remove the dubious check which attempted to duplicate the operating
system's behavior.
2020-08-10 20:43:45 +02:00
Lance Bachmeier
dec85a4a57
Remove trailing whitespace
2020-08-10 10:33:54 -05:00
Lance Bachmeier
a864971c45
Update std/random.d
...
Co-authored-by: Sebastian Wilzbach <seb@wilzba.ch>
2020-08-10 10:25:45 -05:00
Lance Bachmeier
94132a52f5
Update std/random.d
...
Co-authored-by: Sebastian Wilzbach <seb@wilzba.ch>
2020-08-10 10:25:18 -05:00
Lance Bachmeier
945f9510b1
Update random.d
...
Demonstrate basic usage of uniform01. The existing example is confusing because it mixes in feqrel without any explanation, as you can see from [this question on the forum](https://forum.dlang.org/post/utjsiocsbearbenpaiut@forum.dlang.org ).
2020-08-10 10:09:39 -05:00
The Dlang Bot
54ea896afc
Merge pull request #7587 from MartinNowak/merge_stable
...
merge stable
merged-on-behalf-of: Mathias LANG <pro.mathias.lang@gmail.com>
2020-08-10 13:02:44 +02:00
Martin Nowak
30191913c3
Merge remote-tracking branch 'upstream/stable' into merge_stable
2020-08-10 10:51:19 +02:00
Steven Schveighoffer
6065ce793c
Fix 21131. Detect certain string appending situations and properly
...
handle them.
2020-08-07 13:03:26 +02:00
Vladimir Panteleev
83ceb907f3
Apply suggestions from code review
...
Fix cast style.
Co-authored-by: Sebastian Wilzbach <seb@wilzba.ch>
2020-08-05 10:21:59 +00:00
Vladimir Panteleev
6760a3bca1
std.socket: Add a notice on how to test this module at the top of the file
2020-08-05 09:27:06 +00:00
Vladimir Panteleev
c7a9857b53
std.socket: Remove redundant copy of the Boost Software License
...
- There is already a copy of the full license text in
../LICENSE_1_0.txt.
- There is already a standard "License" DDoc header.
2020-08-05 09:27:06 +00:00
Vladimir Panteleev
44288e7fe7
std.socket: Fix bitrotted disabled unittests
2020-08-05 09:27:06 +00:00
Vladimir Panteleev
6e76625186
std.socket: Replace version=SlowTests with debug=std_socket
...
Have a single switch to control whether to test std.socket "in full"
or not.
2020-08-05 09:27:06 +00:00
Vladimir Panteleev
0a09280594
std.socket: fix Issue 21114: Hide details of "soft" unittests unless built with -debug=std_socket
...
Reduce noise and false alarms in CI logs.
Also improve the printed message on failure, to make it clear that it
is likely a random failure, and that the ignored test failure is not
what's causing the entire test suite run to fail.
2020-08-05 09:27:05 +00:00
Euan Torano
8e03a95457
Fix issue 21113: Use sysctl for thisExePath on BSD.
2020-08-05 10:20:11 +02:00