Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Mike Frysinger <vapier@gentoo.org>
To: gdb-patches@sourceware.org
Cc: Abhijit Halder <abhijit.k.halder@gmail.com>,
	Tom Tromey <tromey@redhat.com>
Subject: Re: PATCH
Date: Tue, 12 Jul 2011 08:34:00 -0000	[thread overview]
Message-ID: <201107120117.42796.vapier@gentoo.org> (raw)
In-Reply-To: <CAOhZP9w83=FF6khgRnmhV8ZfwiNgkhgitJX3tJsk_-=MLG=-4g@mail.gmail.com>

[-- Attachment #1: Type: Text/Plain, Size: 1033 bytes --]

On Tuesday, July 12, 2011 00:24:15 Abhijit Halder wrote:

please do not top post in your replies

> How if we just put a condition check whether the entered string after
> pipe (|) is numeric. For e.g.
> (gdb) thread apply all bt | grep foobar
> Here the entered string after | is grep foobar which is not numeric.
> But here (gdb) print var | 0x50 is numeric.

that wont work as it's "EXPR | EXPR".  so you could do:
(gdb) print x | x

or if your variable was named "vim", it's impossible to determine the user's 
intention if they wrote something like:
(gdb) print x | vim
do they want the variable "vim" ?  or do they want to shell out to `vim` ?

i think we'll have to introduce a dedicated operator here that doesn't show up 
in C expressions.  how about "|&" ?  this is a bashism for doing 
redirection+pipe in one go, so it'll be somewhat familiar to people.

along those lines, i wonder if generic redirection operators would be useful 
too.  something like:
(gdb) thread apply all bt >& file
-mike

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

  reply	other threads:[~2011-07-12  5:18 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-09 13:09 PATCH Abhijit Halder
2011-07-09 19:06 ` PATCH oza Pawandeep
2011-07-11 12:13   ` PATCH Abhijit Halder
2011-07-11 13:42     ` PATCH Abhijit Halder
2011-07-10  7:47 ` PATCH Mike Frysinger
2011-07-11 21:10 ` PATCH Tom Tromey
2011-07-12  0:51   ` PATCH Abhijit Halder
2011-07-12  7:15     ` PATCH Abhijit Halder
2011-07-12  8:34       ` Mike Frysinger [this message]
2011-07-12  9:01         ` PATCH Abhijit Halder
2011-07-12 17:31           ` PATCH Mike Frysinger
2011-07-12 17:49             ` PATCH Matt Rice
2011-07-12 19:25               ` PATCH Mike Frysinger
2011-07-12 19:49       ` PATCH Tom Tromey
2011-07-12 20:43         ` PATCH Mike Frysinger
2011-07-13  8:45           ` PATCH Abhijit Halder
2011-07-15 14:15             ` PATCH Abhijit Halder
2011-07-15 20:49               ` PATCH Tom Tromey
2011-07-20 19:25               ` PATCH Sergio Durigan Junior
2011-07-21 11:08           ` gdb output pipelining to shell (was: Re: PATCH) Pedro Alves

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=201107120117.42796.vapier@gentoo.org \
    --to=vapier@gentoo.org \
    --cc=abhijit.k.halder@gmail.com \
    --cc=gdb-patches@sourceware.org \
    --cc=tromey@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