Boost logo

Boost-Commit :

From: thomas.klimpel_at_[hidden]
Date: 2008-05-22 07:30:10


Author: klimpel
Date: 2008-05-22 07:30:09 EDT (Thu, 22 May 2008)
New Revision: 45646
URL: http://svn.boost.org/trac/boost/changeset/45646

Log:
replaced reinterpret_cast with traits::complex_ptr and std::complex<float> with traits::complex_f

Text files modified:
   sandbox/boost/numeric/bindings/lapack/geev.hpp | 20 ++++++++++----------
   sandbox/boost/numeric/bindings/lapack/geqrf.hpp | 20 ++++++++++----------
   sandbox/boost/numeric/bindings/lapack/trevc.hpp | 8 ++++----
   sandbox/boost/numeric/bindings/lapack/trexc.hpp | 8 ++++----
   4 files changed, 28 insertions(+), 28 deletions(-)

Modified: sandbox/boost/numeric/bindings/lapack/geev.hpp
==============================================================================
--- sandbox/boost/numeric/bindings/lapack/geev.hpp (original)
+++ sandbox/boost/numeric/bindings/lapack/geev.hpp 2008-05-22 07:30:09 EDT (Thu, 22 May 2008)
@@ -99,11 +99,11 @@
       {
         int info;
         LAPACK_CGEEV(jobvl, jobvr, n,
- reinterpret_cast<fcomplex_t *>(a), lda,
- reinterpret_cast<fcomplex_t *>(w),
- reinterpret_cast<fcomplex_t *>(vl), ldvl,
- reinterpret_cast<fcomplex_t *>(vr), ldvr,
- reinterpret_cast<fcomplex_t *>(work), lwork,
+ traits::complex_ptr(a), lda,
+ traits::complex_ptr(w),
+ traits::complex_ptr(vl), ldvl,
+ traits::complex_ptr(vr), ldvr,
+ traits::complex_ptr(work), lwork,
                      rwork, &info);
         return info;
       }
@@ -116,11 +116,11 @@
       {
         int info;
         LAPACK_ZGEEV(jobvl, jobvr, n,
- reinterpret_cast<dcomplex_t *>(a), lda,
- reinterpret_cast<dcomplex_t *>(w),
- reinterpret_cast<dcomplex_t *>(vl), ldvl,
- reinterpret_cast<dcomplex_t *>(vr), ldvr,
- reinterpret_cast<dcomplex_t *>(work), lwork,
+ traits::complex_ptr(a), lda,
+ traits::complex_ptr(w),
+ traits::complex_ptr(vl), ldvl,
+ traits::complex_ptr(vr), ldvr,
+ traits::complex_ptr(work), lwork,
                      rwork, &info);
         return info;
       }

Modified: sandbox/boost/numeric/bindings/lapack/geqrf.hpp
==============================================================================
--- sandbox/boost/numeric/bindings/lapack/geqrf.hpp (original)
+++ sandbox/boost/numeric/bindings/lapack/geqrf.hpp 2008-05-22 07:30:09 EDT (Thu, 22 May 2008)
@@ -70,27 +70,27 @@
 
       inline
       void geqrf (int const m, int const n,
- std::complex<float>* a, int const lda,
- std::complex<float>* tau, std::complex<float>* work,
+ traits::complex_f* a, int const lda,
+ traits::complex_f* tau, traits::complex_f* work,
                   int const lwork, int& info)
       {
         LAPACK_CGEQRF (&m, &n,
- reinterpret_cast<fcomplex_t*> (a), &lda,
- reinterpret_cast<fcomplex_t*> (tau),
- reinterpret_cast<fcomplex_t*> (work), &lwork, &info );
+ traits::complex_ptr (a), &lda,
+ traits::complex_ptr (tau),
+ traits::complex_ptr (work), &lwork, &info );
       }
       
 
       inline
       void geqrf (int const m, int const n,
- std::complex<double>* a, int const lda,
- std::complex<double>* tau, std::complex<double>* work,
+ traits::complex_d* a, int const lda,
+ traits::complex_d* tau, traits::complex_d* work,
                   int const lwork, int& info)
       {
         LAPACK_ZGEQRF (&m, &n,
- reinterpret_cast<dcomplex_t*> (a), &lda,
- reinterpret_cast<dcomplex_t*> (tau),
- reinterpret_cast<dcomplex_t*> (work), &lwork, &info );
+ traits::complex_ptr (a), &lda,
+ traits::complex_ptr (tau),
+ traits::complex_ptr (work), &lwork, &info );
       }
       
     }

Modified: sandbox/boost/numeric/bindings/lapack/trevc.hpp
==============================================================================
--- sandbox/boost/numeric/bindings/lapack/trevc.hpp (original)
+++ sandbox/boost/numeric/bindings/lapack/trevc.hpp 2008-05-22 07:30:09 EDT (Thu, 22 May 2008)
@@ -65,8 +65,8 @@
 
       inline
       void trevc (char const side, char const howmny, const logical_t* select, int const n,
- std::complex<float>* t, int const ldt, std::complex<float>* vl, int const ldvl, std::complex<float>* vr, int const ldvr,
- int const mm, int& m, std::complex<float>* work, int& info)
+ traits::complex_f* t, int const ldt, traits::complex_f* vl, int const ldvl, traits::complex_f* vr, int const ldvr,
+ int const mm, int& m, traits::complex_f* work, int& info)
       {
         LAPACK_CTREVC (&side, &howmny, select, &n, traits::complex_ptr(t), &ldt, traits::complex_ptr(vl), &ldvl,
                         traits::complex_ptr(vr), &ldvr, &mm, &m, traits::complex_ptr(work+n), traits::complex_ptr(work), &info);
@@ -74,8 +74,8 @@
 
       inline
       void trevc (char const side, char const howmny, const logical_t* select, int const n,
- std::complex<double>* t, int const ldt, std::complex<double>* vl, int const ldvl, std::complex<double>* vr, int const ldvr,
- int const mm, int& m, std::complex<double>* work, int& info)
+ traits::complex_d* t, int const ldt, traits::complex_d* vl, int const ldvl, traits::complex_d* vr, int const ldvr,
+ int const mm, int& m, traits::complex_d* work, int& info)
       {
         LAPACK_ZTREVC (&side, &howmny, select, &n, traits::complex_ptr(t), &ldt,
                              traits::complex_ptr(vl), &ldvl, traits::complex_ptr(vr), &ldvr,

Modified: sandbox/boost/numeric/bindings/lapack/trexc.hpp
==============================================================================
--- sandbox/boost/numeric/bindings/lapack/trexc.hpp (original)
+++ sandbox/boost/numeric/bindings/lapack/trexc.hpp 2008-05-22 07:30:09 EDT (Thu, 22 May 2008)
@@ -51,10 +51,10 @@
       int trexc_work_size( int const n, double ) {return n;}
 
       inline
- int trexc_work_size( int const n, std::complex<float> ) {return 0;}
+ int trexc_work_size( int const n, traits::complex_f ) {return 0;}
 
       inline
- int trexc_work_size( int const n, std::complex<double> ) {return 0;}
+ int trexc_work_size( int const n, traits::complex_d ) {return 0;}
     }
 
     // Get the minimum size of the work array.
@@ -82,7 +82,7 @@
 
       inline
       void trexc (char const compq, int const n,
- std::complex<float>* t, int const ldt, std::complex<float>* q, int const ldq, int& ifst, int& ilst,
+ traits::complex_f* t, int const ldt, traits::complex_f* q, int const ldq, int& ifst, int& ilst,
                  float* work, int& info)
       {
         LAPACK_CTREXC (&compq, &n, traits::complex_ptr(t), &ldt, traits::complex_ptr(q), &ldq, &ifst, &ilst, &info);
@@ -90,7 +90,7 @@
 
       inline
       void trexc (char const compq, int const n,
- std::complex<double>* t, int const ldt, std::complex<double>* q, int const ldq, int& ifst, int& ilst,
+ traits::complex_d* t, int const ldt, traits::complex_d* q, int const ldq, int& ifst, int& ilst,
                  double* work, int& info)
       {
         LAPACK_ZTREXC (&compq, &n, traits::complex_ptr(t), &ldt, traits::complex_ptr(q), &ldq, &ifst, &ilst, &info);


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk