Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r64772 - in sandbox/SOC/2010/process: boost/process boost/process/detail libs/process/doc libs/process/example libs/process/test
From: boris_at_[hidden]
Date: 2010-08-12 18:03:38


Author: bschaeling
Date: 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
New Revision: 64772
URL: http://svn.boost.org/trac/boost/changeset/64772

Log:
Renamed environment_t to environment
Updated documentation
Added:
   sandbox/SOC/2010/process/libs/process/doc/future.qbk (contents, props changed)
   sandbox/SOC/2010/process/libs/process/doc/headers.qbk (contents, props changed)
   sandbox/SOC/2010/process/libs/process/doc/introduction.qbk
      - copied, changed from r64759, /sandbox/SOC/2010/process/libs/process/doc/preface.qbk
Removed:
   sandbox/SOC/2010/process/libs/process/doc/preface.qbk
Text files modified:
   sandbox/SOC/2010/process/boost/process/context.hpp | 4 ++--
   sandbox/SOC/2010/process/boost/process/detail/posix_helpers.hpp | 6 +++---
   sandbox/SOC/2010/process/boost/process/detail/windows_helpers.hpp | 4 ++--
   sandbox/SOC/2010/process/boost/process/environment.hpp | 2 +-
   sandbox/SOC/2010/process/boost/process/operations.hpp | 4 ++--
   sandbox/SOC/2010/process/boost/process/self.hpp | 8 ++++----
   sandbox/SOC/2010/process/libs/process/doc/Jamfile.jam | 2 ++
   sandbox/SOC/2010/process/libs/process/doc/asyncio.qbk | 2 +-
   sandbox/SOC/2010/process/libs/process/doc/communication.qbk | 4 ++--
   sandbox/SOC/2010/process/libs/process/doc/context.qbk | 6 +++---
   sandbox/SOC/2010/process/libs/process/doc/introduction.qbk | 4 ++--
   sandbox/SOC/2010/process/libs/process/doc/process.qbk | 19 +++++++++++++------
   sandbox/SOC/2010/process/libs/process/example/create_child_context.cpp | 2 +-
   sandbox/SOC/2010/process/libs/process/test/child.cpp | 9 ++++-----
   sandbox/SOC/2010/process/libs/process/test/environment.cpp | 34 +++++++++++++++++-----------------
   sandbox/SOC/2010/process/libs/process/test/self.cpp | 6 +++---
   16 files changed, 62 insertions(+), 54 deletions(-)

Modified: sandbox/SOC/2010/process/boost/process/context.hpp
==============================================================================
--- sandbox/SOC/2010/process/boost/process/context.hpp (original)
+++ sandbox/SOC/2010/process/boost/process/context.hpp 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -77,7 +77,7 @@
     /**
      * Environment variables.
      */
- environment_t environment;
+ environment env;
 
     /**
      * Constructs a process context.
@@ -100,7 +100,7 @@
             STD_ERROR_HANDLE))),
 #endif
         work_dir(self::get_work_dir()),
- environment(self::get_environment())
+ env(self::get_environment())
     {
     }
 

Modified: sandbox/SOC/2010/process/boost/process/detail/posix_helpers.hpp
==============================================================================
--- sandbox/SOC/2010/process/boost/process/detail/posix_helpers.hpp (original)
+++ sandbox/SOC/2010/process/boost/process/detail/posix_helpers.hpp 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -50,12 +50,12 @@
  * string of the form var=value. The caller is responsible for
  * freeing them.
  */
-inline std::pair<std::size_t, char**> environment_to_envp(const environment_t &env)
+inline std::pair<std::size_t, char**> environment_to_envp(const environment &env)
 {
     std::size_t nargs = env.size();
     char **envp = new char*[nargs + 1];
- environment_t::size_type i = 0;
- for (environment_t::const_iterator it = env.begin(); it != env.end(); ++it)
+ environment::size_type i = 0;
+ for (environment::const_iterator it = env.begin(); it != env.end(); ++it)
     {
         std::string s = it->first + "=" + it->second;
         envp[i] = new char[s.size() + 1];

Modified: sandbox/SOC/2010/process/boost/process/detail/windows_helpers.hpp
==============================================================================
--- sandbox/SOC/2010/process/boost/process/detail/windows_helpers.hpp (original)
+++ sandbox/SOC/2010/process/boost/process/detail/windows_helpers.hpp 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -47,7 +47,7 @@
  * the environment's content. This string is of the form
  * var1=value1\\0var2=value2\\0\\0.
  */
-inline boost::shared_array<char> environment_to_windows_strings(environment_t &env)
+inline boost::shared_array<char> environment_to_windows_strings(environment &env)
 {
     boost::shared_array<char> envp;
 
@@ -59,7 +59,7 @@
     else
     {
         std::string s;
- for (environment_t::const_iterator it = env.begin(); it != env.end(); ++it)
+ for (environment::const_iterator it = env.begin(); it != env.end(); ++it)
         {
             s += it->first + "=" + it->second;
             s.push_back(0);

Modified: sandbox/SOC/2010/process/boost/process/environment.hpp
==============================================================================
--- sandbox/SOC/2010/process/boost/process/environment.hpp (original)
+++ sandbox/SOC/2010/process/boost/process/environment.hpp 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -44,7 +44,7 @@
  * This is provided for-free by the map container used to implement this
  * type, and this behavior is required by Windows systems.
  */
-typedef std::map<std::string, std::string> environment_t;
+typedef std::map<std::string, std::string> environment;
 
 }
 }

Modified: sandbox/SOC/2010/process/boost/process/operations.hpp
==============================================================================
--- sandbox/SOC/2010/process/boost/process/operations.hpp (original)
+++ sandbox/SOC/2010/process/boost/process/operations.hpp 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -211,7 +211,7 @@
     std::vector<bool> closeflags(maxdescs, true);
     std::pair<std::size_t, char**> argv = detail::collection_to_argv(args);
     std::pair<std::size_t, char**> envp =
- detail::environment_to_envp(ctx.environment);
+ detail::environment_to_envp(ctx.env);
 
     pid_t pid = fork();
     if (pid == -1)
@@ -309,7 +309,7 @@
     strcpy_s(workdir.get(), ctx.work_dir.size() + 1, ctx.work_dir.c_str());
 
     boost::shared_array<char> envstrs =
- detail::environment_to_windows_strings(ctx.environment);
+ detail::environment_to_windows_strings(ctx.env);
 
     if (CreateProcessA(exe.get(), cmdline.get(), NULL, NULL, TRUE, 0,
         envstrs.get(), workdir.get(), &startup_info, &pi) == 0)

Modified: sandbox/SOC/2010/process/boost/process/self.hpp
==============================================================================
--- sandbox/SOC/2010/process/boost/process/self.hpp (original)
+++ sandbox/SOC/2010/process/boost/process/self.hpp 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -74,9 +74,9 @@
      * Returns the current process environment variables. Modifying the
      * returned object has no effect on the current environment.
      */
- static environment_t get_environment()
+ static environment get_environment()
     {
- environment_t e;
+ environment e;
 
 #if defined(BOOST_POSIX_API)
 # if defined(__APPLE__)
@@ -89,7 +89,7 @@
         {
             std::string s = *env;
             std::string::size_type pos = s.find('=');
- e.insert(environment_t::value_type(s.substr(0, pos),
+ e.insert(environment::value_type(s.substr(0, pos),
                 s.substr(pos + 1)));
             ++env;
         }
@@ -108,7 +108,7 @@
             {
                 std::string s = env;
                 std::string::size_type pos = s.find('=');
- e.insert(environment_t::value_type(s.substr(0, pos),
+ e.insert(environment::value_type(s.substr(0, pos),
                     s.substr(pos + 1)));
                 env += s.size() + 1;
             }

Modified: sandbox/SOC/2010/process/libs/process/doc/Jamfile.jam
==============================================================================
--- sandbox/SOC/2010/process/libs/process/doc/Jamfile.jam (original)
+++ sandbox/SOC/2010/process/libs/process/doc/Jamfile.jam 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -20,6 +20,8 @@
         [ glob ../../../boost/process/detail/*.hpp ]
     :
         <doxygen:param>PREDEFINED=BOOST_PROCESS_DOXYGEN
+ <doxygen:param>HIDE_UNDOC_CLASSES=YES
+ <doxygen:param>HIDE_UNDOC_MEMBERS=YES
     ;
 
 xml process : process.qbk ;

Modified: sandbox/SOC/2010/process/libs/process/doc/asyncio.qbk
==============================================================================
--- sandbox/SOC/2010/process/libs/process/doc/asyncio.qbk (original)
+++ sandbox/SOC/2010/process/libs/process/doc/asyncio.qbk 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -1,6 +1,6 @@
 [section:asyncio Asynchronous I/O]
 
-Just like the streams from the C++ standard library _pistream_ and _postream_ only support synchronous (or blocking) I/O. For asynchronous I/O Boost.Process provides the class _pipe_.
+Just like the streams from the C++ standard _pistream_ and _postream_ only support synchronous (or blocking) I/O. For asynchronous I/O Boost.Process provides the class _pipe_.
 
 [import ../example/async_io.cpp]
 [async_io]

Modified: sandbox/SOC/2010/process/libs/process/doc/communication.qbk
==============================================================================
--- sandbox/SOC/2010/process/libs/process/doc/communication.qbk (original)
+++ sandbox/SOC/2010/process/libs/process/doc/communication.qbk 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -4,12 +4,12 @@
 
 [create_child_context_pipe]
 
-It depends on the stream behavior classes whether parameters can be passed to constructors. _behavior_pipe_ requires a parameter as it needs to know whether the pipe will be attached to an input or output stream of the child process.
+It depends on the stream behavior classes whether parameters are expected. _behavior_pipe_ requires a parameter as it needs to know whether the pipe will be attached to an input or output stream of the child process.
 
 If a parent process wants to communicate with a child process the return value of _create_child_ should not be discarded. The return value of type _child_ provides access to the newly created child process. Among others, the member functions _child_get_stdin_, _child_get_stdout_ and _child_get_stderr_ are provided to access the other ends of the child process' standard streams.
 
 [caution You must not call _child_get_stdin_, _child_get_stdout_ and _child_get_stderr_ if you didn't configure the standard streams to be redirected to the parent process.]
 
-The streams returned by _child_get_stdin_, _child_get_stdout_ and _child_get_stderr_ are used similarly to streams from the C++ standard library. The type of the return values is either _pistream_ and _postream_ (depending on whether they are input or output streams). These classes are derived from `std::istream` and `std::ostream` and provide two additional member functions `close()` and `handle()`. You use the latter member function for asynchronous I/O.
+The streams returned by _child_get_stdin_, _child_get_stdout_ and _child_get_stderr_ are used similarly to streams from the C++ standard. The type of the return values is either _pistream_ and _postream_ (depending on whether they are input or output streams). These classes are derived from `std::istream` and `std::ostream` and provide two additional member functions `close()` and `handle()`. You use the latter member function for asynchronous I/O.
 
 [endsect]

Modified: sandbox/SOC/2010/process/libs/process/doc/context.qbk
==============================================================================
--- sandbox/SOC/2010/process/libs/process/doc/context.qbk (original)
+++ sandbox/SOC/2010/process/libs/process/doc/context.qbk 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -2,17 +2,17 @@
 
 Apart from the executable name and command line options a third parameter can be passed to _create_child_: The _context_ class is used to configure the runtime context of a new process.
 
-The _context_ class provides only a few member variables. You can set the process name with `context::process_name`, the work directory with `context::work_dir` and environment variables with `context::environment`.
+The _context_ class provides only a few member variables. You can set the process name with `context::process_name`, the work directory with `context::work_dir` and environment variables with `context::env`.
 
 [import ../example/create_child_context.cpp]
 [create_child_context_configuration]
 
-In practice you are probably more often using the member variables `context::stdin_behavior`, `context::stdout_behavior` and `context::stderr_behavior`. It depends on these settings how the standard streams of a child process will be configured.
+In practice you are probably more often using the member variables `context::stdin_behavior`, `context::stdout_behavior` and `context::stderr_behavior`. It depends on them how standard streams of a child process are configured.
 
 The type of these three member variables is `boost::shared_ptr<boost::process::behavior::stream>`. _behavior_stream_ is the base class of a small hierarchy of behavior classes. Boost.Process provides the following stream behavior classes:
 
-* _behavior_close_
 * _behavior_inherit_
+* _behavior_close_
 * _behavior_pipe_
 * _behavior_named_pipe_
 * _behavior_dummy_

Added: sandbox/SOC/2010/process/libs/process/doc/future.qbk
==============================================================================
--- (empty file)
+++ sandbox/SOC/2010/process/libs/process/doc/future.qbk 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -0,0 +1,38 @@
+[section:future_improvements Future improvements]
+
+This is a collection of some ideas on how Boost.Process could be improved in the future.
+
+[h3 Communicate with a parent process]
+
+While it's rather easy to communicate with a child process through the `child` class Boost.Process could provide a `parent` class to make it as easy to communicate with a parent process. This would be especially helpful to easily support asynchronous I/O as the standard streams only support blocking I/O operations.
+
+Here's how such a program could look like:
+
+ boost::asio::io_service ioservice;
+
+ void handler(const boost::system::error_code &ec)
+ {
+ }
+
+ int main()
+ {
+ boost::process::parent p;
+ boost::process::postream &os = p.get_stdin();
+ boost::process::pipe write_end(ioservice, os.handle().release());
+ boost::asio::async_write(write_end, boost::asio::buffer("Hello, world!"), handler);
+ ioservice.run();
+ }
+
+[h3 Create a snapshot of system processes]
+
+As of today Boost.Process is most useful when creating and managing child processes. Boost.Process could provide a free-standing function `create_snapshot` though to create a snapshot of all system processes.
+
+ int main()
+ {
+ std::vector<boost::process::process> processes;
+ boost::process::create_snapshot(std::back_inserter(processes));
+ boost::process::process p = processes.front();
+ int exit_code = p.wait();
+ }
+
+[endsect]

Added: sandbox/SOC/2010/process/libs/process/doc/headers.qbk
==============================================================================
--- (empty file)
+++ sandbox/SOC/2010/process/libs/process/doc/headers.qbk 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -0,0 +1,15 @@
+[section:headers Header files]
+
+There is only one header file you need to include to make use of all Boost.Process features:
+
+ #include <boost/process/all.hpp>
+
+All examples in this tutorial assume this header file is included.
+
+As many Boost libraries put the main header file in the boost directory you have another option:
+
+ #include <boost/process.hpp>
+
+Please note that the Boost C++ community plans to remove header files from the boost directory. As newer libraries are expected to put all header files in a subdirectory like boost/process including all.hpp is recommended.
+
+[endsect]

Copied: sandbox/SOC/2010/process/libs/process/doc/introduction.qbk (from r64759, /sandbox/SOC/2010/process/libs/process/doc/preface.qbk)
==============================================================================
--- /sandbox/SOC/2010/process/libs/process/doc/preface.qbk (original)
+++ sandbox/SOC/2010/process/libs/process/doc/introduction.qbk 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -1,4 +1,4 @@
-[section:preface Preface]
+[section:introduction Introduction]
 
 Boost.Process is a library to manage system processes. It can be used to:
 
@@ -17,6 +17,6 @@
 [import ../example/create_child.cpp]
 [create_child]
 
-The example searches for an executable hostname in the directories of the enviroment variable PATH and starts it. As the standard output stream is inherited the hostname is printed when you run the example.
+The example searches for an executable hostname in the directories of the environment variable PATH and starts the program. As the standard output stream is inherited the hostname is printed when you run the example.
 
 [endsect]

Deleted: sandbox/SOC/2010/process/libs/process/doc/preface.qbk
==============================================================================
--- sandbox/SOC/2010/process/libs/process/doc/preface.qbk 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
+++ (empty file)
@@ -1,22 +0,0 @@
-[section:preface Preface]
-
-Boost.Process is a library to manage system processes. It can be used to:
-
-* create child processes
-* run shell commands
-* setup environment variables for child processes
-* setup standard streams for child processes
-* communicate with child processes through standard streams (synchronously or asynchronously)
-* wait for processes to exit (synchronously or asynchronously)
-* terminate processes
-
-While Boost.Process does not support platform specific features it provides extension points. Developers can plug in functions, eg. to set the `uid` of a child process on a POSIX system.
-
-Here's an example of how easy it is to start a program with Boost.Process.
-
-[import ../example/create_child.cpp]
-[create_child]
-
-The example searches for an executable hostname in the directories of the enviroment variable PATH and starts it. As the standard output stream is inherited the hostname is printed when you run the example.
-
-[endsect]

Modified: sandbox/SOC/2010/process/libs/process/doc/process.qbk
==============================================================================
--- sandbox/SOC/2010/process/libs/process/doc/process.qbk (original)
+++ sandbox/SOC/2010/process/libs/process/doc/process.qbk 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -11,10 +11,10 @@
     ]
 ]
 
-[def _fork_ [@http://www.opengroup.org/onlinepubs/000095399/functions/fork.html `fork`]]
-[def _execve_ [@http://www.opengroup.org/onlinepubs/009695399/functions/exec.html `execve`]]
-[def _chroot_ [@http://opengroup.org/onlinepubs/007908799/xsh/chroot.html `chroot`]]
-[def _createprocess_ [@http://msdn.microsoft.com/en-us/library/ms682425(VS.85).aspx `CreateProcess`]]
+[def _fork_ [@http://www.opengroup.org/onlinepubs/000095399/functions/fork.html `fork()`]]
+[def _execve_ [@http://www.opengroup.org/onlinepubs/009695399/functions/exec.html `execve()`]]
+[def _chroot_ [@http://opengroup.org/onlinepubs/007908799/xsh/chroot.html `chroot()`]]
+[def _createprocess_ [@http://msdn.microsoft.com/en-us/library/ms682425(VS.85).aspx `CreateProcess()`]]
 [def _sys/wait.h_ [@http://www.opengroup.org/onlinepubs/000095399/basedefs/sys/wait.h.html `sys/wait.h`]]
 [def _child_ [classref boost::process::child `child`]]
 [def _context_ [classref boost::process::context `context`]]
@@ -29,7 +29,7 @@
 [def _behavior_pipe_ [classref boost::process::behavior::pipe `behavior::pipe`]]
 [def _behavior_named_pipe_ [classref boost::process::behavior::named_pipe `behavior::named_pipe`]]
 [def _behavior_dummy_ [classref boost::process::behavior::dummy `behavior::dummy`]]
-[def _behavior_stream_create_ [memberref boost::process::behavior::stream::create `behavior::stream::create()`]]
+[def _behavior_stream_create_ [memberref boost::process::behavior::stream::create `create()`]]
 [def _behavior_stream_get_child_end_ [memberref boost::process::behavior::stream::get_child_end `behavior::stream::get_child_end()`]]
 [def _behavior_stream_get_parent_end_ [memberref boost::process::behavior::stream::get_parent_end `behavior::stream::get_parent_end()`]]
 [def _child_get_stdin_ [memberref boost::process::child::get_stdin `child::get_stdin()`]]
@@ -44,10 +44,11 @@
 [def _shell_ [funcref boost::process::shell `shell()`]]
 [def _find_executable_in_path_ [funcref boost::process::find_executable_in_path `find_executable_in_path()`]]
 
-[include preface.qbk]
+[include introduction.qbk]
 
 [section User Guide]
 
+[include headers.qbk]
 [include childprocess.qbk]
 [include context.qbk]
 [include communication.qbk]
@@ -61,3 +62,9 @@
 [endsect]
 
 [xinclude autodoc.xml]
+
+[section Appendices]
+
+[include future.qbk]
+
+[endsect]

Modified: sandbox/SOC/2010/process/libs/process/example/create_child_context.cpp
==============================================================================
--- sandbox/SOC/2010/process/libs/process/example/create_child_context.cpp (original)
+++ sandbox/SOC/2010/process/libs/process/example/create_child_context.cpp 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -25,7 +25,7 @@
     boost::process::context ctx;
     ctx.process_name = "hostname";
     ctx.work_dir = "C:\\";
- ctx.environment.insert(std::make_pair("new_variable", "value"));
+ ctx.env.insert(std::make_pair("new_variable", "value"));
     boost::process::create_child(exe, args, ctx);
 //]
 }

Modified: sandbox/SOC/2010/process/libs/process/test/child.cpp
==============================================================================
--- sandbox/SOC/2010/process/libs/process/test/child.cpp (original)
+++ sandbox/SOC/2010/process/libs/process/test/child.cpp 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -370,7 +370,7 @@
 BOOST_AUTO_TEST_CASE(test_clear_environment)
 {
     bp::context ctx;
- ctx.environment.erase("TO_BE_QUERIED");
+ ctx.env.erase("TO_BE_QUERIED");
 
 #if defined(BOOST_POSIX_API)
     BOOST_REQUIRE(setenv("TO_BE_QUERIED", "test", 1) != -1);
@@ -401,7 +401,7 @@
 #endif
 
     bp::context ctx;
- ctx.environment.erase("TO_BE_UNSET");
+ ctx.env.erase("TO_BE_UNSET");
     std::pair<bool, std::string> p = get_var_value(ctx, "TO_BE_UNSET");
     BOOST_CHECK(!p.first);
 }
@@ -423,15 +423,14 @@
 #endif
 
     bp::context ctx;
- ctx.environment.insert(bp::environment_t::value_type("TO_BE_SET",
- "some-value"));
+ ctx.env.insert(bp::environment::value_type("TO_BE_SET", "some-value"));
     std::pair<bool, std::string> p = get_var_value(ctx, "TO_BE_SET");
     BOOST_CHECK(p.first);
     BOOST_CHECK_EQUAL(p.second, "'some-value'");
 
 #if defined(BOOST_POSIX_API)
     bp::context ctx2;
- ctx2.environment.insert(bp::environment_t::value_type("TO_BE_SET", ""));
+ ctx2.env.insert(bp::environment::value_type("TO_BE_SET", ""));
     std::pair<bool, std::string> p2 = get_var_value(ctx2, "TO_BE_SET");
     BOOST_CHECK(p2.first);
     BOOST_CHECK_EQUAL(p2.second, "''");

Modified: sandbox/SOC/2010/process/libs/process/test/environment.cpp
==============================================================================
--- sandbox/SOC/2010/process/libs/process/test/environment.cpp (original)
+++ sandbox/SOC/2010/process/libs/process/test/environment.cpp 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -29,7 +29,7 @@
 
 BOOST_AUTO_TEST_CASE(test_current)
 {
- bp::environment_t env1 = bp::self::get_environment();
+ bp::environment env1 = bp::self::get_environment();
     BOOST_CHECK(env1.find("THIS_SHOULD_NOT_BE_DEFINED") == env1.end());
 
 #if defined(BOOST_POSIX_API)
@@ -39,8 +39,8 @@
         "some-value") != 0);
 #endif
 
- bp::environment_t env2 = bp::self::get_environment();
- bp::environment_t::const_iterator it =
+ bp::environment env2 = bp::self::get_environment();
+ bp::environment::const_iterator it =
         env2.find("THIS_SHOULD_BE_DEFINED");
     BOOST_CHECK(it != env2.end());
     BOOST_CHECK_EQUAL(it->second, "some-value");
@@ -49,10 +49,10 @@
 #if defined(BOOST_POSIX_API)
 BOOST_AUTO_TEST_CASE(test_envp)
 {
- bp::environment_t env;
- env.insert(bp::environment_t::value_type("VAR1", "value1"));
- env.insert(bp::environment_t::value_type("VAR2", "value2"));
- env.insert(bp::environment_t::value_type("VAR3", "value3"));
+ bp::environment env;
+ env.insert(bp::environment::value_type("VAR1", "value1"));
+ env.insert(bp::environment::value_type("VAR2", "value2"));
+ env.insert(bp::environment::value_type("VAR3", "value3"));
 
     std::pair<std::size_t, char**> ep = bpd::environment_to_envp(env);
 
@@ -74,9 +74,9 @@
 
 BOOST_AUTO_TEST_CASE(test_envp_unsorted)
 {
- bp::environment_t env;
- env.insert(bp::environment_t::value_type("VAR2", "value2"));
- env.insert(bp::environment_t::value_type("VAR1", "value1"));
+ bp::environment env;
+ env.insert(bp::environment::value_type("VAR2", "value2"));
+ env.insert(bp::environment::value_type("VAR1", "value1"));
 
     std::pair<std::size_t, char**> ep = bpd::environment_to_envp(env);
 
@@ -96,10 +96,10 @@
 #if defined(BOOST_WINDOWS_API)
 BOOST_AUTO_TEST_CASE(test_strings)
 {
- bp::environment_t env;
- env.insert(bp::environment_t::value_type("VAR1", "value1"));
- env.insert(bp::environment_t::value_type("VAR2", "value2"));
- env.insert(bp::environment_t::value_type("VAR3", "value3"));
+ bp::environment env;
+ env.insert(bp::environment::value_type("VAR1", "value1"));
+ env.insert(bp::environment::value_type("VAR2", "value2"));
+ env.insert(bp::environment::value_type("VAR3", "value3"));
 
     boost::shared_array<char> strs =
         bpd::environment_to_windows_strings(env);
@@ -111,9 +111,9 @@
 
 BOOST_AUTO_TEST_CASE(test_strings_unsorted)
 {
- bp::environment_t env;
- env.insert(bp::environment_t::value_type("VAR2", "value2"));
- env.insert(bp::environment_t::value_type("VAR1", "value1"));
+ bp::environment env;
+ env.insert(bp::environment::value_type("VAR2", "value2"));
+ env.insert(bp::environment::value_type("VAR1", "value1"));
 
     boost::shared_array<char> strs =
         bpd::environment_to_windows_strings(env);

Modified: sandbox/SOC/2010/process/libs/process/test/self.cpp
==============================================================================
--- sandbox/SOC/2010/process/libs/process/test/self.cpp (original)
+++ sandbox/SOC/2010/process/libs/process/test/self.cpp 2010-08-12 18:03:20 EDT (Thu, 12 Aug 2010)
@@ -40,7 +40,7 @@
 {
     bp::self &p = bp::self::get_instance();
 
- bp::environment_t env1 = p.get_environment();
+ bp::environment env1 = p.get_environment();
     BOOST_CHECK(env1.find("THIS_SHOULD_NOT_BE_DEFINED") == env1.end());
 
 #if defined(BOOST_POSIX_API)
@@ -50,8 +50,8 @@
         "some-value") != 0);
 #endif
 
- bp::environment_t env2 = p.get_environment();
- bp::environment_t::const_iterator it = env2.find("THIS_SHOULD_BE_DEFINED");
+ bp::environment env2 = p.get_environment();
+ bp::environment::const_iterator it = env2.find("THIS_SHOULD_BE_DEFINED");
     BOOST_CHECK(it != env2.end());
     BOOST_CHECK_EQUAL(it->second, "some-value");
 }


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk