Vladimir Panteleev
cca8661113
Fix Issue 23940 - std.getopt does not assert with options that only differ in case with config.caseInsensitive
2023-05-27 17:38:25 +02:00
Robert burner Schadek
e1f7edae57
Better std.algorithm.iteration.permutations error messages
2023-05-26 05:45:32 +02:00
Dmytro Katyukha
9fadf8ad49
std.path.expandTilde: make compatible with scope and preview='in'
...
When using `expandTilde` with 'priview=in' enabled,
it requires to duplicate value to be able to call this function.
Within this commit the signature of expandTilde function is
changed from `string expandTilde(string inputPath) @safe nothrow`
to `string expandTilde(return scope const string inputPath) @safe nothrow`
thus, after this commit it is possible to use this func in scope
context.
Example case:
```d
/+ dub.sdl:
name "dub-example"
dflags "-preview=in" "-preview=dip1000"
+/
import std.stdio;
import std.path;
@safe:
string fun(in string path) {
return path.expandTilde;
}
void main() {
string p = fun("~/tests/1");
writefln("P: %s", p);
}
```
2023-05-23 01:51:57 +02:00
Dennis
43be08c3a7
Merge pull request #8755 from WalterBright/druntimeToString
...
std.conv integer to string: use core.internal.string
2023-05-21 19:19:28 +02:00
Walter Bright
171a780728
delete unused overload of std.conv.convError()
2023-05-21 16:57:07 +02:00
Walter Bright
4a1210ea1c
std.conv integer to string: use core.internal.string
2023-05-20 23:23:26 -07:00
Dennis
cf97c75385
Merge pull request #8736 from FeepingCreature/fix/issue-23844-immutable-chain
...
Fix issue 23844: Support ranges with immutable fields (like `only` with `immutable struct`) in `chain`.
2023-05-10 11:54:08 +02:00
Cameron Ross
6ff44ed666
fix issue 23881: add std.system.instructionSetArchitecture and std.system.ISA ( #8744 )
2023-05-09 15:37:29 +03:00
Walter Bright
9eb1f83403
std.conv handle default integer-to-string with core.internal.string
2023-05-08 11:30:48 +02:00
Mathis Beer
b9c6e3ca4b
Fix issue 23844: Support ranges with immutable fields (like only
with immutable struct
) in chain
.
...
`only` is a range that may be *mutable*, but not *assignable*. `chain` falls over here because it assumes it can make a struct with ranges, and reassign them with new values, which isn't necessarily the case even if the ranges are not `const`.
Solved by creating a separate tuple of `Rebindable` ranges for this case.
2023-05-03 13:56:04 +02:00
WebFreak001
d35dafbde8
fix 14478: support non-copyable elements in many range algorithms
2023-05-01 18:17:27 +02:00
Denis Feklushkin
2bd1b833f8
Redundant stack grow direction checks removed
2023-04-28 17:36:40 +03:00
FeepingCreature
8a9cfa2677
Fix issue 19642: slide!(No.withPartial): Correctly handle first slide exhausting input range. ( #8738 )
2023-04-24 12:57:21 +03:00
Nick Treleaven
a3a4bdbb27
Fix cstdio links ( #8740 )
...
* Fix cstdio links
Fixes Issue 23834 - std.file : File links to c functions are invalid and
need updating
* Fix whitespace
* No need for prefix underscore
2023-04-24 12:55:48 +03:00
Walter Bright
3ccd2783ab
clarify documentation for std.traits.isIntegral ( #8741 )
2023-04-24 12:54:42 +03:00
Mathis Beer
2f6b2efaf7
Change struct Rebindable to just use cast()
if this is sufficient.
...
This works better at compiletime.
2023-04-19 22:59:43 +00:00
Mathis Beer
b818901e63
Fix issue 22786 (immutable element in maxElement) by always using Rebindable.
2023-04-19 22:59:43 +00:00
FeepingCreature
656ae7905e
Fix issue 22785: joiner
should Unqual
child ranges. ( #8737 )
...
* Fix issue 22785: `joiner` should `Unqual` child ranges.
This allows use with `immutable T[][]` and similar.
---------
Co-authored-by: Petar Kirov <petar.p.kirov@gmail.com>
2023-04-20 01:59:19 +03:00
FeepingCreature
c26d25eecd
Implement Rebindable for non-class/non-array types. ( #8722 )
...
Note that you cannot access a reference to the contained value in struct Rebindable.
2023-04-18 11:33:17 +03:00
Hiroki Noda
336730e471
std.regex: Refactor kicked ( #8732 )
2023-04-17 12:47:12 +03:00
Iain Buclaw
51e5a1b9cb
Add bind to the header table ( #8731 ) ( #8733 )
...
Co-authored-by: Steven Schveighoffer <schveiguy@gmail.com>
2023-04-17 12:46:33 +03:00
Nick Treleaven
01a12f919e
[std.algorithm.searching] Don't instantiate template pred in all
and any
constraints ( #8715 )
...
Fixes Issue 23769 - Lambda isn't a unary predicate for lambda that
doesn't compile.
2023-04-10 19:10:18 +03:00
Ate Eskola
128f75181c
Optimised std.range.chain ( #8713 )
...
* Optimised std.range.chain
Chain now remembers which subrange has the first and the last elements,
eliminating needless work on each usage.
* Style fix.
* No longer needless `.empty` calls in the constructor.
* Improvements based on Razvans observations.
2023-04-07 13:41:04 +03:00
Nick Treleaven
72da991685
[std.algorithm.searching] Fix 2 typos in docs ( #8728 )
2023-03-31 15:38:47 +03:00
Dennis Korpel
17b1a11afd
Remove redundant assumeUnique
in std.path
2023-03-25 04:49:48 +01:00
Jeremy
3c74c2b88a
Add an introduction to the std.json documentation, fix some mistakes in std.curl and replace broken links in std.stdio ( #8724 )
...
* Fix some mistakes in curl.d
* Add an introduction for std.json
* Fix more documentation in curl.d
* Fix broken links in std.stdio documentation
2023-03-21 11:01:15 +02:00
Razvan Nitu
91308f2f64
Merge pull request #8717 from burner/clamp_static_assert_message
...
Better std.algorithm.comparison.clamp error messages
2023-03-16 17:05:06 +08:00
Iain Buclaw
cfd5f13326
Merge remote-tracking branch 'upstream/stable' into merge_stable
2023-03-15 22:42:49 +00:00
Robert burner Schadek
d8c627e037
Better std.algorithm.comparison.clamp error messages
2023-03-15 16:53:20 +01:00
Per Nordlöw
8d03d52db4
Add doc hints between read and readText
2023-03-15 12:52:00 +01:00
RazvanN7
67a47cf39d
Fix Issue 23776 - getSymbolsByUDA fails to fetch symbols from module
2023-03-15 02:48:08 +01:00
RazvanN7
5b3afa5987
Fix std.random to not use this in static contexts
2023-03-15 00:17:00 +01:00
WebFreak001
3b3757af6b
fix 22147: allow @disable this(this) T in DList!T
2023-03-12 19:49:11 +01:00
WebFreak001
e2e1bb4c57
fix isBidirectionalRange with no-postblit .back
2023-03-12 19:49:07 +01:00
Iain Buclaw
65e380c339
std.math.exponential: Fix wrong placement of 1.0 in log1p coefficient
2023-03-11 14:52:06 +01:00
Andrew Lalis
2f8dd14f8d
Add emptyObject() and emptyArray() functions to std/json ( #8559 )
...
* Added emptyObject() and emptyArray() functions, and tests for them.
2023-03-09 15:28:55 +08:00
Razvan Nitu
8143b89ab8
Merge pull request #8700 from ntrel/prefer-__traits
...
[std.traits] Add 'See also: __traits'
2023-03-06 17:33:00 +08:00
Christian Koestlin
1720e03241
fix Issue 6106 - Keep track of changes during replace function
...
The functions without the newly introduced parameter forward
to the full implementation to reduce code duplication.
2023-03-05 12:49:26 +01:00
Geod24
928279879c
Fix a printf prototype in std.traits test
2023-03-04 12:50:04 +01:00
Geod24
ca8fa6c4ca
std.traits: Don't use soon-to-be-deprecated 'in ref'
2023-03-03 21:58:54 +01:00
Razvan Nitu
73e2f6d6e6
Merge pull request #8706 from ntrel/throw-shared
...
[std.concurrency] Avoid throwing shared type
2023-03-03 23:22:08 +08:00
Iain Buclaw
f2ac205a9d
std.math.exponential: Disable use of fyl2x and fyl2xp1 intrinsics on dmd/macOS port
2023-03-03 01:42:36 +01:00
Nick Treleaven
860a8871a7
Avoid throwing shared type
...
See comment for details and:
https://github.com/dlang/dmd/pull/14706#issuecomment-1432027545
2023-03-02 17:00:49 +00:00
Nick Treleaven
fdfaba2e18
Add links to spec/traits
2023-03-02 16:35:27 +00:00
Iain Buclaw
ff4d579e5d
Merge remote-tracking branch 'upstream/stable' into merge_stable
2023-03-01 18:01:33 +00:00
Nick Treleaven
54655c13f1
Add newlines
2023-03-01 11:39:17 +00:00
Nick Treleaven
750cfdb523
Change note to see also
...
Add isNested.
2023-03-01 11:19:20 +00:00
Iain Buclaw
e74d997522
fix Issue 23750 - log1p for floats/doubles not actually providing extra accuracy
2023-03-01 12:13:52 +01:00
Geod24
0dffb006ac
Change a unittest in std.traits for upcoming deprecation
2023-02-28 15:49:24 +01:00
Geod24
2e8f217ae9
Change how preview=in is detected
...
This is a minor internal change, but will allow us to deprecate in ref at the parser level.
2023-02-28 12:56:43 +01:00