mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-14 11:32:34 +00:00
Avoid needlessly casting away const qualifiers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46876 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
33663fc104
commit
547ca537b6
@ -1001,7 +1001,7 @@ protected:
|
||||
|
||||
/// getValueTypeList - Return a pointer to the specified value type.
|
||||
///
|
||||
static MVT::ValueType *getValueTypeList(MVT::ValueType VT);
|
||||
static const MVT::ValueType *getValueTypeList(MVT::ValueType VT);
|
||||
static SDVTList getSDVTList(MVT::ValueType VT) {
|
||||
SDVTList Ret = { getValueTypeList(VT), 1 };
|
||||
return Ret;
|
||||
|
@ -3563,10 +3563,10 @@ void SDNode::Profile(FoldingSetNodeID &ID) {
|
||||
|
||||
/// getValueTypeList - Return a pointer to the specified value type.
|
||||
///
|
||||
MVT::ValueType *SDNode::getValueTypeList(MVT::ValueType VT) {
|
||||
const MVT::ValueType *SDNode::getValueTypeList(MVT::ValueType VT) {
|
||||
if (MVT::isExtendedVT(VT)) {
|
||||
static std::set<MVT::ValueType> EVTs;
|
||||
return (MVT::ValueType *)&(*EVTs.insert(VT).first);
|
||||
return &(*EVTs.insert(VT).first);
|
||||
} else {
|
||||
static MVT::ValueType VTs[MVT::LAST_VALUETYPE];
|
||||
VTs[VT] = VT;
|
||||
|
Loading…
Reference in New Issue
Block a user