projects
/
clsql.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Moving the insert/update tests to after the select as verifying the update works...
[clsql.git]
/
sql
/
utils.lisp
diff --git
a/sql/utils.lisp
b/sql/utils.lisp
index e6176cbb0a18f110620931938172e74b91472d3b..51eef9ebe20b5ff52a1c9c7bbaf821279a37f175 100644
(file)
--- a/
sql/utils.lisp
+++ b/
sql/utils.lisp
@@
-57,11
+57,24
@@
(string identifier))))
(substitute #\_ #\- unescaped)))
(string identifier))))
(substitute #\_ #\- unescaped)))
+#+lispworks
+(defvar +lw-has-without-preemption+
+ #+lispworks6 nil
+ #-lispworks6 t)
+#+lispworks
+(defvar +lw-global-lock+
+ (unless +lw-has-without-preemption+
+ (mp:make-lock :name "CLSQL" :important-p nil :safep t :recursivep nil)))
+
(defmacro without-interrupts (&body body)
#+allegro `(mp:without-scheduling ,@body)
#+clisp `(progn ,@body)
#+cmu `(system:without-interrupts ,@body)
(defmacro without-interrupts (&body body)
#+allegro `(mp:without-scheduling ,@body)
#+clisp `(progn ,@body)
#+cmu `(system:without-interrupts ,@body)
- #+lispworks `(mp:without-preemption ,@body)
+ #+lispworks
+ (if +lw-has-without-preemption+
+ `(mp:without-preemption ,@body)
+ `(mp:with-exclusive-lock (+lw-global-lock+)
+ ,@body))
#+openmcl `(ccl:without-interrupts ,@body)
#+sbcl `(sb-sys::without-interrupts ,@body))
#+openmcl `(ccl:without-interrupts ,@body)
#+sbcl `(sb-sys::without-interrupts ,@body))