summaryrefslogtreecommitdiff
path: root/packages/sundials/src/Bar.hsc
diff options
context:
space:
mode:
authorDominic Steinitz <dominic@steinitz.org>2018-03-29 18:11:24 +0100
committerDominic Steinitz <dominic@steinitz.org>2018-03-29 18:11:24 +0100
commit71a3071a0ecc5c8ebf2b9c0a66a472ff187fdd06 (patch)
tree4067975ada9ba1563bf535b30f98d84cf3c7c209 /packages/sundials/src/Bar.hsc
parent348235b04519f7420a2149e979d076302f869ed9 (diff)
Use more meaningful names
Diffstat (limited to 'packages/sundials/src/Bar.hsc')
-rw-r--r--packages/sundials/src/Bar.hsc9
1 files changed, 4 insertions, 5 deletions
diff --git a/packages/sundials/src/Bar.hsc b/packages/sundials/src/Bar.hsc
index 7d53af9..4fe1b4b 100644
--- a/packages/sundials/src/Bar.hsc
+++ b/packages/sundials/src/Bar.hsc
@@ -10,15 +10,14 @@ import Foreign.C.String
10#include "/Users/dom/sundials/include/nvector/nvector_serial.h" 10#include "/Users/dom/sundials/include/nvector/nvector_serial.h"
11#include "/Users/dom/sundials/include/arkode/arkode.h" 11#include "/Users/dom/sundials/include/arkode/arkode.h"
12 12
13#def typedef struct _generic_N_Vector BarType; 13#def typedef struct _generic_N_Vector SunVector;
14#def typedef struct _N_VectorContent_Serial BazType; 14#def typedef struct _N_VectorContent_Serial SunContent;
15
16 15
17getContentPtr :: Storable a => Ptr b -> IO a 16getContentPtr :: Storable a => Ptr b -> IO a
18getContentPtr ptr = (#peek BarType, content) ptr 17getContentPtr ptr = (#peek SunVector, content) ptr
19 18
20getData :: Storable a => Ptr b -> IO a 19getData :: Storable a => Ptr b -> IO a
21getData ptr = (#peek BazType, data) ptr 20getData ptr = (#peek SunContent, data) ptr
22 21
23arkSMax :: Int 22arkSMax :: Int
24arkSMax = #const ARK_S_MAX 23arkSMax = #const ARK_S_MAX