--- a/include/hpddm-master/src/wrapper.hpp  	2015-05-21 17:25:46.000000000 +0200
+++ b/include/hpddm-master/src/wrapper.hpp	2015-05-22 11:12:32.000000000 +0200
@@ -374,10 +374,6 @@
 }
 #define HPDDM_GENERATE_MKL_VML(C, T)                                                                         \
 template<>                                                                                                   \
-inline void Wrapper<T>::diag(const int& n, const T* const d, const T* const in, T* const out) {              \
-    diag(n, i__1, d, in, out);                                                                               \
-}                                                                                                            \
-template<>                                                                                                   \
 inline void Wrapper<T>::diag(const int& m, const int& n, const T* const d,                                   \
                              const T* const in, T* const out) {                                              \
     if(in)                                                                                                   \
@@ -386,7 +382,14 @@
     else                                                                                                     \
         for(int i = 0; i < n; ++i)                                                                           \
             v ## C ## Mul(m, d, out + i * m, out + i * m);                                                   \
-}
+}                                                                                                            \
+template<>								\
+inline void Wrapper<T>::diag(const int& n, const T* const d, const T* const in, T* const out) {              \
+    diag(n, i__1, d, in, out);                                                                               \
+}                                                                                                            
+    
+    
+    
 HPDDM_GENERATE_MKL(s, float)
 HPDDM_GENERATE_MKL(d, double)
 HPDDM_GENERATE_MKL(c, std::complex<float>)
