Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/gen/common/generator/constant.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,11 @@

(defmethod generate-binding ((generator generator) (entity claw.spec:foreign-variable) &key)
(let* ((name (c-name->lisp (claw.spec:format-full-foreign-entity-name entity) :variable))
(type (check-entity-known (claw.spec:foreing-variable-type entity)))
(type (check-entity-known (claw.spec:foreign-variable-type entity)))
(value (claw.spec:foreign-entity-value entity))
(decorated-name (format-symbol (symbol-package name) "*~A*" name)))
(export-symbol decorated-name)
(if (claw.spec:foreing-variable-external-p entity)
(if (claw.spec:foreign-variable-external-p entity)
`((define-symbol-macro ,decorated-name
,(if (typep type 'claw.spec:foreign-array)
`(cffi:foreign-symbol-pointer ,(claw.spec:foreign-entity-name entity))
Expand All @@ -78,4 +78,4 @@


(defmethod foreign-entity-dependencies ((entity claw.spec:foreign-variable))
(find-foreign-dependencies (claw.spec:foreing-variable-type entity)))
(find-foreign-dependencies (claw.spec:foreign-variable-type entity)))
4 changes: 2 additions & 2 deletions src/gen/iffi/cxx/generator/variable.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

(defun adapt-variable-setter (variable)
(multiple-value-bind (variable-type adapted-p)
(adapt-type (check-entity-known (claw.spec:foreing-variable-type variable)))
(adapt-type (check-entity-known (claw.spec:foreign-variable-type variable)))
(let ((unaliased (claw.spec:unalias-foreign-entity variable-type)))
(unless (or (typep unaliased 'claw.spec:foreign-array)
(typep unaliased 'claw.spec:foreign-const-qualifier))
Expand All @@ -21,7 +21,7 @@

(defun adapt-variable-getter (variable)
(multiple-value-bind (variable-type adapted-p)
(adapt-type (check-entity-known (claw.spec:foreing-variable-type variable)))
(adapt-type (check-entity-known (claw.spec:foreign-variable-type variable)))
(let* ((unaliased (claw.spec:unalias-foreign-entity variable-type))
(array-p (typep unaliased 'claw.spec:foreign-array))
(result-type (if array-p
Expand Down
2 changes: 1 addition & 1 deletion src/resect/prepare.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@
(prepare-type (%resect:declaration-type param-decl))))


(defmethod prepare-declaration ((kind (eql :functino-prototype)) declaration &key)
(defmethod prepare-declaration ((kind (eql :function-prototype)) declaration &key)
(prepare-declaration :function declaration))

(defmethod prepare-declaration ((kind (eql :typedef)) declaration &key)
Expand Down
8 changes: 4 additions & 4 deletions src/spec/entity.lisp
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,9 @@
#:foreign-method-deleted-p

#:foreign-variable
#:foreing-variable-type
#:foreign-variable-type
#:foreign-entity-value
#:foreing-variable-external-p
#:foreign-variable-external-p

#:foreign-templatable-p
#:foreign-entity-template-p
Expand Down Expand Up @@ -549,10 +549,10 @@
:reader foreign-entity-value)
(type :initarg :type
:initform (error ":type missing")
:reader foreing-variable-type)
:reader foreign-variable-type)
(external-p :initarg :external
:initform nil
:reader foreing-variable-external-p)))
:reader foreign-variable-external-p)))


;;;
Expand Down