mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Thomas Weißschuh" <linux@weissschuh.net>
To: Willy Tarreau <w@1wt.eu>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] tools/nolibc: add stdbool.h header
Date: Sat, 27 Jul 2024 10:50:30 +0200	[thread overview]
Message-ID: <4bdae1cf-ad18-4d16-b6cb-8f4e8adab867@t-8ch.de> (raw)
In-Reply-To: <20240725-nolibc-stdbool-v1-1-a6ee2c80bcde@weissschuh.net>

On 2024-07-25 19:10:44+0000, Thomas Weißschuh wrote:
> stdbool.h is very simple.
> Provide an implementation for the user convenience.
> 
> Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
> ---
>  tools/include/nolibc/Makefile  |  1 +
>  tools/include/nolibc/nolibc.h  |  3 ++-
>  tools/include/nolibc/stdbool.h | 16 ++++++++++++++++
>  3 files changed, 19 insertions(+), 1 deletion(-)

<snip>

> diff --git a/tools/include/nolibc/stdbool.h b/tools/include/nolibc/stdbool.h
> new file mode 100644
> index 000000000000..709abed93425
> --- /dev/null
> +++ b/tools/include/nolibc/stdbool.h
> @@ -0,0 +1,16 @@
> +/* SPDX-License-Identifier: LGPL-2.1 OR MIT */
> +/*
> + * Boolean types support for NOLIBC
> + * Copyright (C) 2024 Thomas Weißschuh <linux@weissschuh.net>
> + */
> +
> +#ifndef _NOLIBC_STDBOOL_H
> +#define _NOLIBC_STDBOOL_H
> +
> +#define _Bool bool

For the record:

The claim "stdbool.h is very simple" didn't hold up very well.
I managed to switch up this #define.
I'll fix it up when applying.

> +#define true 1
> +#define false 0
> +
> +#define __bool_true_false_are_defined 1
> +
> +#endif /* _NOLIBC_STDBOOL_H */

      parent reply	other threads:[~2024-07-27  8:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-25 17:10 Thomas Weißschuh
2024-07-25 17:14 ` Willy Tarreau
2024-07-27  8:50 ` Thomas Weißschuh [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4bdae1cf-ad18-4d16-b6cb-8f4e8adab867@t-8ch.de \
    --to=linux@weissschuh.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=w@1wt.eu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®