Forcibly inline bit_cast when building with GCC.

R=svenpanne@chromium.org

Review URL: https://codereview.chromium.org/595773002

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@24130 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
bmeurer@chromium.org 2014-09-23 06:30:15 +00:00
parent 803761a9f9
commit 54ceb48005

View File

@ -230,7 +230,7 @@ struct CompileAssert {};
// WARNING: if Dest or Source is a non-POD type, the result of the memcpy // WARNING: if Dest or Source is a non-POD type, the result of the memcpy
// is likely to surprise you. // is likely to surprise you.
template <class Dest, class Source> template <class Dest, class Source>
inline Dest bit_cast(const Source& source) { V8_INLINE Dest bit_cast(Source const& source) {
COMPILE_ASSERT(sizeof(Dest) == sizeof(Source), VerifySizesAreEqual); COMPILE_ASSERT(sizeof(Dest) == sizeof(Source), VerifySizesAreEqual);
Dest dest; Dest dest;