mirror of
https://github.com/dlang/phobos.git
synced 2025-05-05 09:30:49 +03:00
Remove obsolete TypeTuple references
Replace following names: std.typetuple -> std.meta TypeTuple -> AliasSeq ParameterTypeTuple -> Parameters FieldTypeTuple -> Fields std.traits requires more work than search/replace and is left unchanged.
This commit is contained in:
parent
8d9d606ef8
commit
d698887729
48 changed files with 643 additions and 645 deletions
|
@ -162,7 +162,7 @@ template stateSize(T)
|
|||
static if (is(T == class) || is(T == interface))
|
||||
enum stateSize = __traits(classInstanceSize, T);
|
||||
else static if (is(T == struct) || is(T == union))
|
||||
enum stateSize = FieldTypeTuple!T.length || isNested!T ? T.sizeof : 0;
|
||||
enum stateSize = Fields!T.length || isNested!T ? T.sizeof : 0;
|
||||
else static if (is(T == void))
|
||||
enum size_t stateSize = 0;
|
||||
else
|
||||
|
@ -560,12 +560,12 @@ Forwards each of the methods in `funs` (if defined) to `member`.
|
|||
*/
|
||||
/*package*/ string forwardToMember(string member, string[] funs...)
|
||||
{
|
||||
string result = " import std.traits : hasMember, ParameterTypeTuple;\n";
|
||||
string result = " import std.traits : hasMember, Parameters;\n";
|
||||
foreach (fun; funs)
|
||||
{
|
||||
result ~= "
|
||||
static if (hasMember!(typeof("~member~"), `"~fun~"`))
|
||||
auto ref "~fun~"(ParameterTypeTuple!(typeof("~member~"."~fun~")) args)
|
||||
auto ref "~fun~"(Parameters!(typeof("~member~"."~fun~")) args)
|
||||
{
|
||||
return "~member~"."~fun~"(args);
|
||||
}\n";
|
||||
|
|
|
@ -250,7 +250,7 @@ unittest
|
|||
}
|
||||
|
||||
import std.algorithm, std.conv, std.exception, std.range, std.traits,
|
||||
std.typecons, std.typetuple;
|
||||
std.typecons;
|
||||
version(unittest) import std.random, std.stdio;
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue