[clpython-devel] Re: CLPython on SBCL

Leonardo Varuzza varuzza at gmail.com
Wed May 14 00:42:47 UTC 2008


Making the instance of python-function in REPL:

(make-instance 'py-function :fname '|cl-user::f|)

I got the same error:


============ SLDB =====================

The value 8595300352 is not of type LIST.
   [Condition of type TYPE-ERROR]

Restarts:
  0: [ABORT-REQUEST] Abort handling SLIME request.
  1: [TERMINATE-THREAD] Terminate this thread (#<THREAD "repl-thread"
{100385CA01}>)

Backtrace:
  0: (NTHCDR 10 8595300352)[:EXTERNAL]
  1: (SB-PCL::SLOT-UNBOUND-INTERNAL #<error printing object>)
  2: (SB-PCL::SET-ARG-INFO #<error printing object>)[:EXTERNAL]
  3: ((SB-PCL::FAST-METHOD INITIALIZE-INSTANCE :AFTER
(STANDARD-GENERIC-FUNCTION)) #<error printing object>)[:EXTERNAL]
  4: ((LAMBDA (SB-PCL::.PV. SB-PCL::.NEXT-METHOD-CALL. SB-PCL::.ARG0.
SB-INT:&MORE SB-PCL::.DFUN-MORE-CONTEXT. SB-PCL::.DFUN-MORE-COUNT.))
#<error printing object>)
  5: ((SB-PCL::FAST-METHOD MAKE-INSTANCE (CLASS)) #<unavailable
argument> #<unavailable argument> #<FUNCALLABLE-PYTHON-CLASS
PY-FUNCTION>)[:EXTERNAL]
  6: (SB-INT:SIMPLE-EVAL-IN-LEXENV (MAKE-INSTANCE (QUOTE PY-FUNCTION)
:FNAME (QUOTE |cl-user::f|)) #<NULL-LEXENV>)
  7: (SWANK::EVAL-REGION "(make-instance 'py-function :fname '|cl-user::f|)

=======================================

On Tue, May 13, 2008 at 7:57 PM, Leonardo Varuzza <varuzza at gmail.com> wrote:
> Executing the code bellow for the first time
>
>  (run "
>  def foo(x):
>   return x+1")
>
>  I got this error on SBCL 1.0.16:
>
>  ===== SLDB output
>  ========================================================================
>  The value 563404091678720 is not of type LIST.
>    [Condition of type TYPE-ERROR]
>
>  Restarts:
>   0: [ABORT-REQUEST] Abort handling SLIME request.
>   1: [TERMINATE-THREAD] Terminate this thread (#<THREAD "repl-thread"
>  {1003601911}>)
>
>  Backtrace:
>   0: (NTHCDR 10 563404091678720)[:EXTERNAL]
>
>   1: (SB-PCL::SLOT-UNBOUND-INTERNAL #<error printing object>)
>   2: (SB-PCL::SET-ARG-INFO #<error printing object>)[:EXTERNAL]
>
>   3: ((SB-PCL::FAST-METHOD INITIALIZE-INSTANCE :AFTER
>  (STANDARD-GENERIC-FUNCTION)) #<error printing object>)[:EXTERNAL]
>   4: ((LAMBDA (SB-PCL::.PV. SB-PCL::.NEXT-METHOD-CALL. SB-PCL::.ARG0.
>  SB-INT:&MORE SB-PCL::.DFUN-MORE-CONTEXT. SB-PCL::.DFUN-MORE-COUNT.))
>
> #<error printing object>)
>   5: ((SB-PCL::FAST-METHOD MAKE-INSTANCE (CLASS)) #<unavailable
>  argument> #<unavailable argument> #<FUNCALLABLE-PYTHON-CLASS
>  PY-FUNCTION>)[:EXTERNAL]
>   6: (MAKE-PY-FUNCTION)[:EXTERNAL]
>   7: ((LAMBDA NIL))
>   8: (CALL-WITH-PY-ERRORS #<CLOSURE (LAMBDA NIL) {1002EBCB39}>)
>   9: ((LAMBDA (&KEY GLOBALS-HANDLER (CALL-PRELOAD-HOOK T) (MODULE-NAME
>  (QUOTE "__main__")) (MODULE-PATH (QUOTE "")))) :GLOBALS-HANDLER NIL
>  :CALL-PRELOAD-HOOK T :MODULE-NAME "__main__" :MODULE-PATH "")
>   10: (RUN-PYTHON-AST (CLPYTHON.AST.NODE:|module-stmt|
>  (CLPYTHON.AST.NODE:|suite-stmt| (#))))[:EXTERNAL]
>   11: (SB-INT:SIMPLE-EVAL-IN-LEXENV (RUN "
>  def foo(x):
>   return x+1") #<NULL-LEXENV>)
>   12: (SWANK::EVAL-REGION "(run \"
>  def foo(x):
>   return x+1\")
>
>  " T)
>  ===== SLDB output
>  ========================================================================
>
>  Trying to run the code again I get this other error:
>
>  ===== SLDB output
>  ========================================================================
>  Heap exhausted: 8491880448 bytes available, 4503772160131216
>  requested. PROCEED WITH CAUTION!
>    [Condition of type SB-KERNEL::HEAP-EXHAUSTED-ERROR]
>
>  Restarts:
>   0: [ABORT-REQUEST] Abort handling SLIME request.
>   1: [TERMINATE-THREAD] Terminate this thread (#<THREAD "repl-thread"
>  {1003676911}>)
>
>  Backtrace:
>   0: (SB-KERNEL::HEAP-EXHAUSTED-ERROR 8491880448 4503772160131216)
>   1: ("foreign function: #x41DEC2")
>   2: ("foreign function: #x40BCFE")
>   3: ("foreign function: #x41953F")
>   4: ("foreign function: #x4196A5")
>   5: ("foreign function: #x41A900")
>   6: ("foreign function: #x41B0DC")
>   7: ("foreign function: #x41DF1A")
>   8: (SB-PCL::ALLOCATE-STANDARD-FUNCALLABLE-INSTANCE #<SB-PCL::WRAPPER
>  #<FUNCALLABLE-PYTHON-CLASS PY-FUNCTION> {10026C51C1}> NIL)
>
>   9: ((SB-PCL::FAST-METHOD MAKE-INSTANCE (CLASS)) #<unavailable
>  argument> #<unavailable argument> #<FUNCALLABLE-PYTHON-CLASS
>  PY-FUNCTION>)[:EXTERNAL]
>   10: (MAKE-PY-FUNCTION)[:EXTERNAL]
>   11: ((LAMBDA NIL))
>   12: (CALL-WITH-PY-ERRORS #<CLOSURE (LAMBDA NIL) {10032A0D79}>)
>   13: ((LAMBDA (&KEY GLOBALS-HANDLER (CALL-PRELOAD-HOOK T) (MODULE-NAME
>  (QUOTE "__main__")) (MODULE-PATH (QUOTE "")))) :GLOBALS-HANDLER NIL
>  :CALL-PRELOAD-HOOK T :MODULE-NAME "__main__" :MODULE-PATH "")
>   14: (RUN-PYTHON-AST (CLPYTHON.AST.NODE:|module-stmt|
>  (CLPYTHON.AST.NODE:|suite-stmt| (#))))[:EXTERNAL]
>   15: (SB-INT:SIMPLE-EVAL-IN-LEXENV (RUN "
>  def foo(x):
>   return x+1") #<NULL-LEXENV>)
>   16: (SWANK::EVAL-REGION "(run \"
>  def foo(x):
>   return x+1\")
>
>  " T)
>   17: ((LAMBDA NIL))
>   18: ((SB-PCL::FAST-METHOD SWANK-BACKEND:CALL-WITH-SYNTAX-HOOKS (T))
>  #<unused argument> #<unused argument> #<CLOSURE (LAMBDA NIL)
>  {1002CCA469}>)
>   19: (SWANK::CALL-WITH-BUFFER-SYNTAX #<CLOSURE (LAMBDA NIL) {1002CCA469}>)
>   20: (SB-INT:SIMPLE-EVAL-IN-LEXENV (SWANK:LISTENER-EVAL "(run \"
>  def foo(x):
>   return x+1\")
>
>  ") #<NULL-LEXENV>)
>  ===== SLDB output
>  ========================================================================
>
>
>
>  --
>  The most fundamental particles in this product are held together by a
>  "gluing" force about which little is currently known and whose
>  adhesive power can therefore not be permanently guaranteed.
>



-- 
The most fundamental particles in this product are held together by a
"gluing" force about which little is currently known and whose
adhesive power can therefore not be permanently guaranteed.



More information about the Clpython-devel mailing list