From: Bill Wendling Date: Sun, 1 Dec 2013 03:36:07 +0000 (+0000) Subject: Use 'unsigned char' to get this past gcc error message: X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=6e59964b45eae56f1de25e8bb6326a347df7cb56;p=oota-llvm.git Use 'unsigned char' to get this past gcc error message: error: invalid conversion from 'unsigned char' to '{anonymous}::Sequence' git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196004 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Transforms/ObjCARC/ObjCARCOpts.cpp b/lib/Transforms/ObjCARC/ObjCARCOpts.cpp index 1cc665b2e02..2976df6b9de 100644 --- a/lib/Transforms/ObjCARC/ObjCARCOpts.cpp +++ b/lib/Transforms/ObjCARC/ObjCARCOpts.cpp @@ -432,7 +432,7 @@ namespace { bool Partial; /// The current position in the sequence. - Sequence Seq : 8; + unsigned char Seq : 8; /// Unidirectional information about the current sequence. RRInfo RRI; @@ -498,7 +498,7 @@ namespace { } Sequence GetSeq() const { - return Seq; + return static_cast(Seq); } void ClearSequenceProgress() { @@ -538,7 +538,8 @@ namespace { void PtrState::Merge(const PtrState &Other, bool TopDown) { - Seq = MergeSeqs(Seq, Other.Seq, TopDown); + Seq = MergeSeqs(static_cast(Seq), static_cast(Other.Seq), + TopDown); KnownPositiveRefCount &= Other.KnownPositiveRefCount; // If we're not in a sequence (anymore), drop all associated state.