mirror of
https://github.com/dlang/phobos.git
synced 2025-04-29 14:40:30 +03:00
Merge pull request #4278 from jmdavis/deprecations
Move some deprecations along.
This commit is contained in:
commit
56e6d25a2d
5 changed files with 6 additions and 38 deletions
|
@ -4,8 +4,12 @@ language: d
|
|||
d: dmd-2.071.0
|
||||
install:
|
||||
- wget "https://raw.githubusercontent.com/dlang/dmd/master/src/checkwhitespace.d" -O ../checkwhitespace.d
|
||||
- wget -q -O dscanner "http://releases.dlang.io/dscanner/0.3.0-git/dscanner"
|
||||
- chmod +x dscanner
|
||||
- git clone https://github.com/Hackerpilot/Dscanner
|
||||
- (cd Dscanner && git checkout tags/v0.4.0-alpha2)
|
||||
- (cd Dscanner && git submodule update --init --recursive)
|
||||
- (cd Dscanner && make githash debug)
|
||||
- mv Dscanner/dsc .
|
||||
- rm -rf Dscanner
|
||||
script:
|
||||
- (cd .. && rdmd ./checkwhitespace.d $(find phobos -name '*.d'))
|
||||
- grep -E "(for|foreach|foreach_reverse|if|while)\(" $(find . -name '*.d'); test $? -eq 1
|
||||
|
|
17
std/array.d
17
std/array.d
|
@ -2681,23 +2681,6 @@ if (isDynamicArray!A)
|
|||
_data.capacity = arr.length;
|
||||
}
|
||||
|
||||
//Broken function. To be removed.
|
||||
static if (is(T == immutable))
|
||||
{
|
||||
// Explicitly undocumented. It will be removed in March 2016. @@@DEPRECATED_2016-03@@@
|
||||
deprecated ("Using this constructor will break the type system. Please fix your code to use `Appender!(T[]).this(T[] arr)' directly.")
|
||||
this(Unqual!T[] arr) pure nothrow
|
||||
{
|
||||
this(cast(T[]) arr);
|
||||
}
|
||||
|
||||
//temporary: For resolving ambiguity:
|
||||
this(typeof(null))
|
||||
{
|
||||
this(cast(T[]) null);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Reserve at least newCapacity elements for appending. Note that more elements
|
||||
* may be reserved than requested. If newCapacity <= capacity, then nothing is
|
||||
|
|
|
@ -737,17 +737,6 @@ unittest
|
|||
|
||||
struct BitArray
|
||||
{
|
||||
// Explicitly undocumented. They will be removed in April 2016. @@@DEPRECATED_2016-04@@@
|
||||
deprecated("Use the constructor instead.")
|
||||
@property void ptr(size_t* p) pure nothrow @nogc { _ptr = p; }
|
||||
deprecated("Use .opIndex instead.")
|
||||
@property inout(size_t)* ptr() inout pure nothrow @nogc { return _ptr; }
|
||||
|
||||
deprecated("Use .length instead.")
|
||||
@property void len(size_t v) pure nothrow @nogc { _len = v; }
|
||||
deprecated("Use .length instead.")
|
||||
@property size_t len() const pure nothrow @nogc { return _len; }
|
||||
|
||||
private:
|
||||
|
||||
import std.format : FormatSpec;
|
||||
|
|
|
@ -1423,10 +1423,6 @@ unittest //more alias this opCast
|
|||
assert(!mayPointTo(A.init, p));
|
||||
}
|
||||
|
||||
// Explicitly undocumented. It will be removed in May 2016. @@@DEPRECATED_2016-05@@@
|
||||
deprecated ("pointsTo is ambiguous. Please use either of doesPointTo or mayPointTo")
|
||||
alias pointsTo = doesPointTo;
|
||||
|
||||
/+
|
||||
Returns true if the field at index $(D i) in ($D T) shares its address with another field.
|
||||
|
||||
|
|
|
@ -701,10 +701,6 @@ unittest
|
|||
// functions without committing to a particular type of the function.
|
||||
}
|
||||
|
||||
// Explicitly undocumented. It will be removed in March 2016. @@@DEPRECATED_2016-03@@@
|
||||
deprecated("Please use std.functional.partial instead")
|
||||
alias curry = partial;
|
||||
|
||||
// tests for partially evaluating callables
|
||||
unittest
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue