Skip to content

Commit

Permalink
Fix issue 22701: Remove is(typeof()) callable check in std.typecons.a…
Browse files Browse the repository at this point in the history
…pply.

It creates unreadable template errors for no benefit.
  • Loading branch information
FeepingCreature committed Jan 26, 2022
1 parent e772416 commit ac5c8d0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion std/typecons.d
Original file line number Diff line number Diff line change
Expand Up @@ -4042,7 +4042,7 @@ template apply(alias fun)
import std.functional : unaryFun;

auto apply(T)(auto ref T t)
if (isInstanceOf!(Nullable, T) && is(typeof(unaryFun!fun(T.init.get))))
if (isInstanceOf!(Nullable, T))
{
alias FunType = typeof(unaryFun!fun(T.init.get));

Expand Down

0 comments on commit ac5c8d0

Please sign in to comment.