From: Jonathan Wakely <jwakely.gcc@gmail.com>
To: naveen yadav <yad.naveen@gmail.com>
Cc: gcc-help <gcc-help@gcc.gnu.org>
Subject: Re: Modification required in cout function
Date: Fri, 06 Jan 2012 09:48:00 -0000 [thread overview]
Message-ID: <CAH6eHdSzpduCogSbnXDWEX5D_xevZ=z+Ptus8G7aA1Vj+R_YHw@mail.gmail.com> (raw)
In-Reply-To: <CAH6eHdQqVdk+zEoPZhe+H4ire9xP38pD26YWC9pmg+2ivu=Wvg@mail.gmail.com>
On 6 January 2012 09:45, Jonathan Wakely wrote:
> On 6 January 2012 09:28, naveen yadav wrote:
>> Dear All,
>>
>> I want to modify cout source code in GCC such that it will not print
>> any thing on the screen.
>>
>> The reason is I have very large already compile code(distrubited in
>> lib form) and it is not possible to recompile. so i left with no
>> option but to modify in GCC code. Will you pls let me know where I can do it .
>
>
> Can't you just redirect the program's output to /dev/null when you run
> the program?
>
> Or close the file descriptor in your program's main() function?
>
> Or duplicate the file descriptor in main() to redirect the output to a file?
Or replace std::cout's streambuf with a different streambuf that
doesn't write to stdout.
I could probably think of more ways to do it without altering the
standard library.
next prev parent reply other threads:[~2012-01-06 9:46 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-01-06 9:28 naveen yadav
2012-01-06 9:46 ` naveen yadav
2012-01-06 9:46 ` Jonathan Wakely
2012-01-06 9:48 ` Jonathan Wakely [this message]
2012-01-06 12:41 ` naveen yadav
2012-01-06 12:41 ` Jonathan Wakely
2012-01-06 12:55 ` naveen yadav
2012-01-06 14:51 ` Jonathan Wakely
2012-01-07 12:02 ` naveen yadav
2012-01-07 17:32 ` Jonathan Wakely
2012-01-09 12:29 ` naveen yadav
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='CAH6eHdSzpduCogSbnXDWEX5D_xevZ=z+Ptus8G7aA1Vj+R_YHw@mail.gmail.com' \
--to=jwakely.gcc@gmail.com \
--cc=gcc-help@gcc.gnu.org \
--cc=yad.naveen@gmail.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).