Commit Graph

7 Commits

Author SHA1 Message Date
Michael J. Spencer
93e5ec2cba KillTheDoctor: Cleanup error_code usage.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120986 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-06 04:28:01 +00:00
Michael J. Spencer
a1d942fb70 KillTheDoctor: Fix spelling.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120985 91177308-0d34-0410-b5e6-96231b3b80d8
2010-12-06 04:27:52 +00:00
Michael J. Spencer
1f6efa3996 Merge System into Support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120298 91177308-0d34-0410-b5e6-96231b3b80d8
2010-11-29 18:16:10 +00:00
Michael J. Spencer
fae76d0734 This is the first step in adding sane error handling support to LLVMSystem.
The system API's will be shifted over to returning an error_code, and returning
other return values as out parameters to the function.

Code that needs to check error conditions will use the errc enum values which
are the same as the posix_errno defines (EBADF, E2BIG, etc...), and are
compatable with the error codes in WinError.h due to some magic in system_error.

An example would be:

if (error_code ec = KillEvil("Java")) { // error_code can be converted to bool.
  handle_error(ec);
}

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119360 91177308-0d34-0410-b5e6-96231b3b80d8
2010-11-16 18:31:52 +00:00
Michael J. Spencer
b269ff7267 KillTheDoctor: Fix 2008 build. I'm actually surprised 2010 defines all of these, many are non-standard posix/unix extensions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116597 91177308-0d34-0410-b5e6-96231b3b80d8
2010-10-15 18:13:02 +00:00
Michael J. Spencer
09203ac3dd KillTheDoctor: Fix VS2008 build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116330 91177308-0d34-0410-b5e6-96231b3b80d8
2010-10-12 19:27:44 +00:00
Michael J. Spencer
bbb9ea7b70 Add KillTheDoctor.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116216 91177308-0d34-0410-b5e6-96231b3b80d8
2010-10-11 19:55:38 +00:00