diff options
| author | Evan Cheng <evan.cheng@apple.com> | 2009-10-04 05:25:42 +0000 | 
|---|---|---|
| committer | Evan Cheng <evan.cheng@apple.com> | 2009-10-04 05:25:42 +0000 | 
| commit | cd4c17aeaf2371a9cd9befb35768ea2ae520630b (patch) | |
| tree | 8b2a7ee39342251a4faca3c8c0b88178d67c014b | |
| parent | d5931cd2b742169c2edf39466571c967ba2a0f3b (diff) | |
| download | bcm5719-llvm-cd4c17aeaf2371a9cd9befb35768ea2ae520630b.tar.gz bcm5719-llvm-cd4c17aeaf2371a9cd9befb35768ea2ae520630b.zip  | |
Rename enum NumOccurrences to NumOccurrencesFlag since there is a member named NumOccurrences.
llvm-svn: 83273
| -rw-r--r-- | llvm/include/llvm/Support/CommandLine.h | 14 | 
1 files changed, 8 insertions, 6 deletions
diff --git a/llvm/include/llvm/Support/CommandLine.h b/llvm/include/llvm/Support/CommandLine.h index 4fcca1d431e..dc73979bb09 100644 --- a/llvm/include/llvm/Support/CommandLine.h +++ b/llvm/include/llvm/Support/CommandLine.h @@ -67,7 +67,7 @@ void MarkOptionsChanged();  // Flags permitted to be passed to command line arguments  // -enum NumOccurrences {          // Flags for the number of occurrences allowed +enum NumOccurrencesFlag {      // Flags for the number of occurrences allowed    Optional        = 0x01,      // Zero or One occurrence    ZeroOrMore      = 0x02,      // Zero or more occurrences allowed    Required        = 0x03,      // One occurrence required @@ -162,8 +162,8 @@ public:    const char *HelpStr;    // The descriptive text message for --help    const char *ValueStr;   // String describing what the value of this option is -  inline enum NumOccurrences getNumOccurrencesFlag() const { -    return static_cast<enum NumOccurrences>(Flags & OccurrencesMask); +  inline enum NumOccurrencesFlag getNumOccurrencesFlag() const { +    return static_cast<enum NumOccurrencesFlag>(Flags & OccurrencesMask);    }    inline enum ValueExpected getValueExpectedFlag() const {      int VE = Flags & ValueMask; @@ -197,7 +197,7 @@ public:      Flags |= Flag;    } -  void setNumOccurrencesFlag(enum NumOccurrences Val) { +  void setNumOccurrencesFlag(enum NumOccurrencesFlag Val) {      setFlag(Val, OccurrencesMask);    }    void setValueExpectedFlag(enum ValueExpected Val) { setFlag(Val, ValueMask); } @@ -720,8 +720,10 @@ template<> struct applicator<const char*> {    static void opt(const char *Str, Opt &O) { O.setArgStr(Str); }  }; -template<> struct applicator<NumOccurrences> { -  static void opt(NumOccurrences NO, Option &O) { O.setNumOccurrencesFlag(NO); } +template<> struct applicator<NumOccurrencesFlag> { +  static void opt(NumOccurrencesFlag NO, Option &O) { +    O.setNumOccurrencesFlag(NO); +  }  };  template<> struct applicator<ValueExpected> {    static void opt(ValueExpected VE, Option &O) { O.setValueExpectedFlag(VE); }  | 

