Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Tom Tromey <tromey@redhat.com>
To: Keith Seitz <keiths@redhat.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [RFA] Add method overload resolution to expression parser
Date: Wed, 14 Oct 2009 19:29:00 -0000	[thread overview]
Message-ID: <m3eip5ai63.fsf@fleche.redhat.com> (raw)
In-Reply-To: <20091014191710.GA1785@caradoc.them.org> (Daniel Jacobowitz's 	message of "Wed, 14 Oct 2009 15:17:10 -0400")

>>>>> "Daniel" == Daniel Jacobowitz <drow@false.org> writes:

Daniel> Maybe we need to get that merged, then, instead of complicated
Daniel> lifetime-confusing hacks around it :-)

Yeah, this would help in several scenarios.  E.g., it would let us
memoize Python Type objects.

However, in this case, if we made a new type, I think we would still
need a new expression operator.  My reasoning is that we are selecting
an overload at expression evaluation time, so we are using the type in a
fundamentally different way from a cast operator.

I don't think I understand why we do this overload selection at
evaluation time and not during the parse.  (It is often preferable to
defer operations until evaluation time so that we can apply them to a
convenience variable's possibly-mutable type -- but that does not apply
in this instance.)

Tom


  reply	other threads:[~2009-10-14 19:29 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-01 18:06 Keith Seitz
2009-09-24 19:30 ` Keith Seitz
2009-10-13 21:24 ` Daniel Jacobowitz
2009-10-14 18:54   ` Tom Tromey
2009-10-14 19:17     ` Daniel Jacobowitz
2009-10-14 19:29       ` Tom Tromey [this message]
2009-10-13 21:24 ` Tom Tromey
2009-11-09 21:55   ` Keith Seitz
2009-11-09 22:22     ` Tom Tromey
2009-11-09 23:35       ` Keith Seitz
2009-11-10 19:14         ` Daniel Jacobowitz
2009-11-10 22:19           ` Keith Seitz

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=m3eip5ai63.fsf@fleche.redhat.com \
    --to=tromey@redhat.com \
    --cc=gdb-patches@sourceware.org \
    --cc=keiths@redhat.com \
    /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