[arrayfire] 62/84: Using AF_THROW_MSG instead of THROW in cpp/array.cpp

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Mon Jan 4 23:22:26 UTC 2016


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to branch master
in repository arrayfire.

commit 301b21d2c70d39093ed9c144c429ceae8c8d0e6c
Author: Shehzan Mohammed <shehzan at arrayfire.com>
Date:   Tue Dec 29 10:44:01 2015 -0500

    Using AF_THROW_MSG instead of THROW in cpp/array.cpp
---
 src/api/cpp/array.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/api/cpp/array.cpp b/src/api/cpp/array.cpp
index 76b6e2e..ef9a06a 100644
--- a/src/api/cpp/array.cpp
+++ b/src/api/cpp/array.cpp
@@ -32,7 +32,7 @@ namespace af
     static af_array gforReorder(const af_array in, unsigned dim)
     {
         // This is here to stop gcc from complaining
-        if (dim > 3) THROW(AF_ERR_SIZE);
+        if (dim > 3) AF_THROW_MSG("GFor: Dimension is invalid", AF_ERR_SIZE);
         unsigned order[AF_MAX_DIMS] = {0, 1, 2, dim};
         order[dim] = 3;
         af_array out;
@@ -347,7 +347,7 @@ namespace af
                 case 2: return gen_indexing(*this, z, s0, z, z);
                 case 3: return gen_indexing(*this, z, z, s0, z);
                 case 4: return gen_indexing(*this, z, z, z, s0);
-                default: THROW(AF_ERR_SIZE);
+                default: AF_THROW_MSG("ndims for Array is invalid", AF_ERR_SIZE);
             }
         }
         else {

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/arrayfire.git



More information about the debian-science-commits mailing list