mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-23 11:13:28 +01:00
Make StringSaver::save less ambiguous.
Previously, an expression such as Saver.save(std::string("foo") + "bar") didn't compile because there is an ambiguity as to whether the argument is of const Twine& or StringRef. llvm-svn: 301512
This commit is contained in:
parent
0447f26de6
commit
566703b56d
@ -26,7 +26,7 @@ public:
|
|||||||
StringRef save(const char *S) { return save(StringRef(S)); }
|
StringRef save(const char *S) { return save(StringRef(S)); }
|
||||||
StringRef save(StringRef S);
|
StringRef save(StringRef S);
|
||||||
StringRef save(const Twine &S) { return save(StringRef(S.str())); }
|
StringRef save(const Twine &S) { return save(StringRef(S.str())); }
|
||||||
StringRef save(std::string &S) { return save(StringRef(S)); }
|
StringRef save(const std::string &S) { return save(StringRef(S)); }
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user