Skip to content

Commit

Permalink
Add convenience accessor to Triple for OS == NaCl
Browse files Browse the repository at this point in the history
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169565 91177308-0d34-0410-b5e6-96231b3b80d8
  • Loading branch information
eliben committed Dec 7, 2012
1 parent e40aecf commit 105fdbb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions include/llvm/ADT/Triple.h
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,11 @@ class Triple {
return getOS() == Triple::Win32 || isOSCygMing();
}

/// \brief Tests whether the OS is NaCl (Native Client)
bool isOSNaCl() const {
return getOS() == Triple::NaCl;
}

/// \brief Tests whether the OS uses the ELF binary format.
bool isOSBinFormatELF() const {
return !isOSDarwin() && !isOSWindows();
Expand Down

0 comments on commit 105fdbb

Please sign in to comment.