Skip to content
Snippets Groups Projects
Commit 75ca6f4e authored by Liam Healy's avatar Liam Healy
Browse files

Eliminate calls to grid:complex-to-cl

Eliminate calls to grid:complex-to-cl because it has been eliminated;
rely on fsbv:object to do the conversion.  Use new function
#'fsbv:converter-defined-p.
parent 3cd314c8
No related branches found
No related tags found
No related merge requests found
;; Expand the body of a defmfun ;; Expand the body of a defmfun
;; Liam Healy 2009-04-13 22:07:13EDT body-expand.lisp ;; Liam Healy 2009-04-13 22:07:13EDT body-expand.lisp
;; Time-stamp: <2010-11-27 13:54:41EST body-expand.lisp> ;; Time-stamp: <2010-11-27 22:08:19EST body-expand.lisp>
;; ;;
;; Copyright 2009, 2010 Liam M. Healy ;; Copyright 2009, 2010 Liam M. Healy
;; Distributed under the terms of the GNU General Public License ;; Distributed under the terms of the GNU General Public License
...@@ -86,21 +86,17 @@ ...@@ -86,21 +86,17 @@
"Generate a form that calls the appropriate converter from C/GSL to CL." "Generate a form that calls the appropriate converter from C/GSL to CL."
(or (or
#+fsbv #+fsbv
(if (member (grid:st-actual-type decl) fsbv::*libffi-struct-defs*) (if (fsbv:converter-defined-p (grid:st-actual-type decl))
`((fsbv:object ,(grid:st-symbol decl) ',(grid:st-actual-type decl)))) `((fsbv:object ,(grid:st-symbol decl) ',(grid:st-actual-type decl))))
#-fsbv nil #-fsbv nil
(case (grid:st-actual-type decl) (case (grid:st-actual-type decl)
(sf-result (sf-result
`((val ,(grid:st-symbol decl)) `((val ,(grid:st-symbol decl))
(err ,(grid:st-symbol decl)))) (err ,(grid:st-symbol decl))))
(sf-result-e10 (sf-result-e10
`((val ,(grid:st-symbol decl) 'sf-result-e10) `((val ,(grid:st-symbol decl) 'sf-result-e10)
(e10 ,(grid:st-symbol decl)) (e10 ,(grid:st-symbol decl))
(err ,(grid:st-symbol decl) 'sf-result-e10))) (err ,(grid:st-symbol decl) 'sf-result-e10)))
(grid:complex-double-c
`((grid:complex-to-cl ,(grid:st-symbol decl) 'grid:complex-double-c)))
(grid:complex-float-c
`((grid:complex-to-cl ,(grid:st-symbol decl) 'grid:complex-float-c)))
(t `((cffi:mem-aref ,(grid:st-symbol decl) ',(grid:st-actual-type decl))))))) (t `((cffi:mem-aref ,(grid:st-symbol decl) ',(grid:st-actual-type decl)))))))
(defun body-expand (name arglist gsl-name c-arguments key-args) (defun body-expand (name arglist gsl-name c-arguments key-args)
...@@ -214,4 +210,3 @@ ...@@ -214,4 +210,3 @@
(not return-supplied-p)) (not return-supplied-p))
(and (null return) return-supplied-p)) (and (null return) return-supplied-p))
clret)))) clret))))
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment