Message from discussion
Embedding interactive interpreter
Path: g2news1.google.com!news2.google.com!postnews.google.com!g4g2000hsf.googlegroups.com!not-for-mail
From: Ryan K <ryankas...@gmail.com>
Newsgroups: comp.lang.python
Subject: Embedding interactive interpreter
Date: Tue, 05 Jun 2007 13:39:17 -0000
Organization: http://groups.google.com
Lines: 9
Message-ID: <1181050757.146862.113550@g4g2000hsf.googlegroups.com>
NNTP-Posting-Host: 67.35.66.31
Mime-Version: 1.0
Content-Type: text/plain; charset="iso-8859-1"
X-Trace: posting.google.com 1181050757 4856 127.0.0.1 (5 Jun 2007 13:39:17 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Tue, 5 Jun 2007 13:39:17 +0000 (UTC)
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1.4) Gecko/20061201 Firefox/2.0.0.4 (Ubuntu-feisty),gzip(gfe),gzip(gfe)
Complaints-To: groups-abuse@google.com
Injection-Info: g4g2000hsf.googlegroups.com; posting-host=67.35.66.31;
posting-account=rx7o5Q0AAABMuaEb2P2kj69iIMJqrXx7
Hi. I am trying to embed an interactive interpreter in a C++
application. I need to capture the output of int
PyRun_InteractiveOne(FILE *fp, const char *filename). Is redirecting
sys.stdout and sys.stderr after initializing the interpreter the best
way to do this?
Thanks,
Ryan