[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.lisp

SBCL : stepping hunchentoot threads

budden

11/8/2015 2:15:00 PM

Hi!

I have the following code:

(in-package :cl-user)

'#.(ql:quickload :hunchentoot)

(defvar *single-acceptor* nil)

(declaim (optimize (debug 3) (safety 3)
(speed 0) (space 0) (compilation-speed 0)))
(proclaim '(optimize (debug 3) (safety 3)
(speed 0) (space 0) (compilation-speed 0)))

(defun inner-fun () (break) "<p>blah-blah-blah</p>")

(defun my-page (&rest ignore)
(declare (ignore ignore))
(concatenate 'string "<html><body>"
(string-downcase (inner-fun))
"</body></html>"))


(defun restart-server ()
(setf hunchentoot:*catch-errors-p* nil)
(when *single-acceptor*
(hunchentoot:stop *single-acceptor*))
(setf *single-acceptor*
(make-instance 'hunchentoot:easy-acceptor :port 2800))
(hunchentoot:start *single-acceptor*)
(hunchentoot:define-easy-handler
(mypage-symbol :uri "/mypage") () (my-page)))

(restart-server)
;; EOF

When I call my-page from my SLIME REPL, it breaks into SLBC (slime debugger). I switch to stepping mode with "s" and stepping works, in accordance to SBCL manual.

When I open http://127.0.0.1:N... wit my web browser,
it breaks into the debugger too. But as I try to switch into stepping mode, minibuffer shows "Evaluation aborted on NIL" and execution continues so that page is send to the browser.

What could be the reason of it? SWANK, SBCL or HUNCHENTOOT?
5 Answers

The Peeler

6/6/2013 9:48:00 PM

0

On Thu, 06 Jun 2013 04:46:50 -0700, The Rectum, the resident psychopath of
sci and scj, FAKING his time zone again and IMPERSONATING his master, The
Peeler, wrote:

>> A good place to drown your 'tarded, crippled daughter,
>> eh dutch pig? The T4 operation lives!
>
> ...also his wife, my Jewish master! Then Dumb Heinie and I could finally move together!

Well, go for it, The Rectum! <BG>

--
Nefesh about The Rectum:
"Now when the Revd tries to think,
He begins to stink."
MID: <a48017af-a595-4fd0-8275-26ebf2e8e8d9@y35g2000pre.googlegroups.com>

The Peeler

6/6/2013 10:09:00 PM

0

On Thu, 6 Jun 2013 23:47:50 +0200, The Peeler
<finishingoff@themoronicRevd.invalid> wrote:

>On Thu, 06 Jun 2013 04:46:50 -0700, The Rectum, the resident psychopath of
>sci and scj, FAKING his time zone again and IMPERSONATING his master, The
>Peeler, wrote:
>
>>> A good place to drown ny 'tarded, crippled jew daughter,
>>> eh? The T4 operation lives!
>>
>> ...also his wife, the Jewish cunt! Then Dumb NEMO and I could finally move together!
>
>We'll, go for it, The Rectum! <BG>

You, SHOULD Grik anus! <GB>

budden

11/8/2015 4:07:00 PM

0

Localized:

(in-package :cl-user)
(declaim (optimize (debug 3) (speed 0) (compilation-speed 0) (space 0)))
(proclaim '(optimize (debug 3) (speed 0) (compilation-speed 0) (space 0)))

(defun outer (x)
"Outer function"
(+ (inner x) (+ x x)))

(defun inner (y)
"Inner function"
(break)
(+ y 4)
)

(defun outer-no-args ()
(outer 5))
;; EOF

Now in SLIME REPL:
(outer-no-args) ; can switch to stepping
(sb-thread:make-thread #'outer-no-args :name "Thread to fail a stepper") ; can't

budden

11/8/2015 5:11:00 PM

0

> Localized:
>
> (in-package :cl-user)
> (declaim (optimize (debug 3) (speed 0) (compilation-speed 0) (space 0)))
> (proclaim '(optimize (debug 3) (speed 0) (compilation-speed 0) (space 0)))
>
> (defun outer (x)
> "Outer function"
> (+ (inner x) (+ x x)))
>
> (defun inner (y)
> "Inner function"
> (break)
> (+ y 4)
> )
>
> (defun outer-no-args ()
> (outer 5))
> ;; EOF
>
> Now in SLIME REPL:
> (outer-no-args) ; can switch to stepping
> (sb-thread:make-thread #'outer-no-args :name "Thread to fail a stepper") ; can't

https://bugs.launchpad.net/sbcl/+b...

budden

11/16/2015 10:18:00 PM

0

Problem is in SBCL. I have the solution. See https://bugs.launchpad.net/sbcl/+b...

> Hi!
>
> I have the following code:
>
> When I call my-page from my SLIME REPL, it breaks into SLBC (slime debugger). I switch to stepping mode with "s" and stepping works, in accordance to SBCL manual.
>
> When I open http://127.0.0.1:N... wit my web browser,
> it breaks into the debugger too. But as I try to switch into stepping mode, minibuffer shows "Evaluation aborted on NIL" and execution continues so that page is send to the browser.
>
> What could be the reason of it? SWANK, SBCL or HUNCHENTOOT?