
Beman Dawes wrote:
"David Abrahams" <dave@boost-consulting.com> wrote in message news:u1wy1wipv.fsf@boost-consulting.com...
Does it worry you that this will potentially expose an implementation detail of the functions (i.e. that they use a system call) which may even differ from platform to platform, making code nonportable?
Some libraries (Boost.Filesystem for example) really shouldn't try to hide the fact that there is an operating system underneath.
What worries me is that with a single blessed system_error_code_type, the Filesystem approach (always implement directly on top of the OS) is imposed upon other libraries that may have other options. A threading library, for example, may sit on top of a pthread_* layer instead of talking directly to the OS; this means that it will get errno error codes back and not GetLastError. Even Boost.Filesystem is possible to implement on top on Microsoft's POSIX-like API and never talk to the OS directly.