Thread overview
[Issue 21681] Can't deduce recursive template function attributes
Dec 17, 2022
Iain Buclaw
Aug 27
Dennis
March 06, 2021
https://issues.dlang.org/show_bug.cgi?id=21681

--- Comment #1 from Илья Ярошенко <ilyayaroshenko@gmail.com> ---
Reduced example:
void foo()(int a)
{
    if (--a)
        bar(a);
}

void bar()(int a)
{
    if (--a)
        foo(a);
}

void main() @safe pure nothrow @nogc
{
    bar(10);
}

==============
onlineapp.d(15): Error: pure function D main cannot call impure function
onlineapp.bar!().bar
onlineapp.d(15): Error: @safe function D main cannot call @system function
onlineapp.bar!().bar
onlineapp.d(7):        onlineapp.bar!().bar is declared here
onlineapp.d(15): Error: @nogc function D main cannot call non-@nogc function
onlineapp.bar!().bar
onlineapp.d(15): Error: function onlineapp.bar!().bar is not nothrow
onlineapp.d(13): Error: nothrow function D main may throw

--
December 17, 2022
https://issues.dlang.org/show_bug.cgi?id=21681

Iain Buclaw <ibuclaw@gdcproject.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P1                          |P2

--
August 27
https://issues.dlang.org/show_bug.cgi?id=21681

Dennis <dkorpel@live.nl> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |dkorpel@live.nl
         Resolution|---                         |DUPLICATE

--- Comment #2 from Dennis <dkorpel@live.nl> ---


*** This issue has been marked as a duplicate of issue 7205 ***

--