Re: [dev] ot: C Standard noreturn

From: Markus Wichmann <nullplan_AT_gmx.net>
Date: Thu, 22 Sep 2016 21:03:57 +0200

On Thu, Sep 22, 2016 at 08:04:44PM +0200, u_AT_netbeisser.de wrote:
> main.c:7:10: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘void’
> noreturn void __stack_chk_fail(void);
>

noreturn is already a return type (in as much as void is one, namely
syntactically), so remove the "void" and you should be fine.

> tried
> void __stack_chk_fail(void) __attribute ((noreturn));
> instead.
>

That however only works with gcc and compatibles.

Ciao,
Markus
Received on Thu Sep 22 2016 - 21:03:57 CEST

This archive was generated by hypermail 2.3.0 : Thu Sep 22 2016 - 21:12:13 CEST