[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdesupport/eigen2/Eigen/src/Core
From: BenoƮt Jacob <jacob.benoit.1 () gmail ! com>
Date: 2009-01-08 20:20:12
Message-ID: 1231446012.406128.789.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 907840 by bjacob:
add missing inline keywords (compilation error) spotted by timvdm
M +2 -0 MatrixStorage.h
M +4 -4 util/Memory.h
--- trunk/kdesupport/eigen2/Eigen/src/Core/MatrixStorage.h #907839:907840
@@ -37,8 +37,10 @@
ei_matrix_array()
{
+ #ifndef EIGEN_DISABLE_UNALIGNED_ARRAY_ASSERT
ei_assert((reinterpret_cast<size_t>(array) & 0xf) == 0
&& "this assertion is explained here: \
http://eigen.tuxfamily.org/api/UnalignedArrayAssert.html **** READ THIS WEB PAGE !!! \
****"); + #endif
}
};
--- trunk/kdesupport/eigen2/Eigen/src/Core/util/Memory.h #907839:907840
@@ -86,13 +86,13 @@
* On allocation error, the returned pointer is undefined, but if exceptions are \
enabled then a std::bad_alloc is thrown.
* The default constructor of T is called.
*/
-template<typename T> T* ei_aligned_new(size_t size)
+template<typename T> inline T* ei_aligned_new(size_t size)
{
void *void_result = ei_aligned_malloc(sizeof(T)*size);
return ::new(void_result) T[size];
}
-template<typename T, bool Align> T* ei_conditional_aligned_new(size_t size)
+template<typename T, bool Align> inline T* ei_conditional_aligned_new(size_t size)
{
void *void_result = ei_conditional_aligned_malloc<Align>(sizeof(T)*size);
return ::new(void_result) T[size];
@@ -120,7 +120,7 @@
ei_aligned_free(ptr);
}
-template<> void ei_conditional_aligned_free<false>(void *ptr)
+template<> inline void ei_conditional_aligned_free<false>(void *ptr)
{
free(ptr);
}
@@ -137,7 +137,7 @@
/** \internal delete objects constructed with ei_aligned_new
* The \a size parameters tells on how many objects to call the destructor of T.
*/
-template<typename T> void ei_aligned_delete(T *ptr, size_t size)
+template<typename T> inline void ei_aligned_delete(T *ptr, size_t size)
{
ei_delete_elements_of_array<T>(ptr, size);
ei_aligned_free(ptr);
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic