Opened 14 years ago

Closed 13 years ago

#1890 closed Bugs (invalid)

Missing parameters in example code

Reported by: dima@… Owned by: Dave Abrahams
Milestone: Boost 1.36.0 Component: python USE GITHUB
Version: Boost 1.35.0 Severity: Problem
Keywords: Cc: rwgk@…

Description

On the page:

http://www.boost.org/doc/libs/1_35_0/libs/python/doc/tutorial/doc/html/python/embedding.html

object ignored = exec("hello = file('hello.txt', 'w')\n"

"hello.write('Hello world!')\n" "hello.close()", main_namespace);

should be:

object ignored = exec("hello = file('hello.txt', 'w')\n"

"hello.write('Hello world!')\n" "hello.close()", main_namespace, main_namespace);

Change History (2)

comment:1 by Daniel James, 14 years ago

Component: DocumentationPython
Owner: changed from Matias Capeletto to Dave Abrahams

comment:2 by Ralf W. Grosse-Kunstleve, 13 years ago

Cc: rwgk@… added
Resolution: invalid
Status: newclosed

svn trunk rev. 55640 verifies that the code as shown under embedding.html compiles and runs as intended. The third argument is optional and defaults to None, which is just fine in this case. I suggest leaving the example as is. Ralf

Note: See TracTickets for help on using tickets.