public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Joseph Myers <joseph@codesourcery.com>
To: Martin Uecker <uecker@tugraz.at>
Cc: Siddhesh Poyarekar <siddhesh@gotplt.org>,
	Andreas Schwab <schwab@suse.de>, <polacek@redhat.com>,
	<gcc-patches@gcc.gnu.org>
Subject: Re: [gcc15] nested functions in C
Date: Tue, 5 Dec 2023 21:08:55 +0000	[thread overview]
Message-ID: <c8c6f86-116c-6d66-cae5-333b5370@codesourcery.com> (raw)
In-Reply-To: <202bfa4a608cd28481bee80d7cec64d1037ec9f7.camel@tugraz.at>

[-- Attachment #1: Type: text/plain, Size: 710 bytes --]

On Mon, 4 Dec 2023, Martin Uecker wrote:

> > The key feature of lambdas (which failed to make it into C23) for this 
> > purpose is that you can't convert them to function pointers, which 
> > eliminates any need for trampolines.
> 
> And also makes them useful only for template-like macro programming,
> but not much else. So my understanding was that this needs to be 
> addressed at some point. 

Where "addressed" probably means some kind of callable object that stores 
more than just a function pointer in order to be able to encapsulate both 
the code address of a lambda and the context it needs to receive 
implicitly.  So still not needing trampolines.

-- 
Joseph S. Myers
joseph@codesourcery.com

  reply	other threads:[~2023-12-05 21:09 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-01 19:33 [PATCH] gcc: Disallow trampolines when -fhardened Marek Polacek
2023-12-01 19:44 ` Andrew Pinski
2023-12-01 20:53   ` Marek Polacek
2023-12-01 21:14     ` Jakub Jelinek
2023-12-07 15:34     ` Eric Botcazou
2023-12-02  9:42 ` Martin Uecker
2023-12-02 10:24   ` Iain Sandoe
2023-12-04 16:26   ` Siddhesh Poyarekar
2023-12-04 16:39     ` Andreas Schwab
2023-12-04 16:45       ` Jakub Jelinek
2023-12-04 16:46       ` Siddhesh Poyarekar
2023-12-04 17:21         ` Martin Uecker
2023-12-04 18:27           ` [gcc15] nested functions in C Siddhesh Poyarekar
2023-12-04 18:48             ` Martin Uecker
2023-12-04 20:35               ` Siddhesh Poyarekar
2023-12-04 21:31                 ` Martin Uecker
2023-12-05 12:32                   ` Siddhesh Poyarekar
2023-12-04 21:33                 ` Joseph Myers
2023-12-04 22:31                   ` Martin Uecker
2023-12-05 21:08                     ` Joseph Myers [this message]
2023-12-05 21:15                       ` Martin Uecker
2023-12-06  7:39                         ` Richard Biener
2023-12-04 18:51             ` Jakub Jelinek
2023-12-04 19:13               ` Martin Uecker
2023-12-04 20:15               ` Siddhesh Poyarekar
2023-12-07 15:42                 ` Eric Botcazou
2023-12-07 15:50                   ` Siddhesh Poyarekar

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=c8c6f86-116c-6d66-cae5-333b5370@codesourcery.com \
    --to=joseph@codesourcery.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=polacek@redhat.com \
    --cc=schwab@suse.de \
    --cc=siddhesh@gotplt.org \
    --cc=uecker@tugraz.at \
    /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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).