This is the mail archive of the kawa@sourceware.org mailing list for the Kawa project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: kawa hanging while running input-parse.scm


That definitely changed something. It may be fixed, but I'm not sure, because I'm hitting another (unrelated?) problem in the same code. See attached for another boiled-down nonsense snippet.

Exception in thread "main" java.lang.InternalError
    at gnu.bytecode.Label.setTypes(Label.java:103)
    at gnu.bytecode.CodeAttr.emitGoto(CodeAttr.java:1609)
    at gnu.bytecode.CodeAttr.emitTailCall(CodeAttr.java:2498)
    at gnu.expr.ApplyExp.compile(ApplyExp.java:511)
    at gnu.expr.ApplyExp.compile(ApplyExp.java:190)
    at gnu.expr.Expression.compileNotePosition(Expression.java:158)
    at gnu.expr.Expression.compileWithPosition(Expression.java:129)
    at gnu.expr.ExitExp.compile(ExitExp.java:42)
    at gnu.expr.Expression.compileWithPosition(Expression.java:132)
    at gnu.expr.IfExp.compile(IfExp.java:125)
    at gnu.expr.IfExp.compile(IfExp.java:54)
    at gnu.kawa.functions.CompileMisc.compileConvert(CompileMisc.java:220)
    at gnu.expr.ApplyExp.inlineCompile(ApplyExp.java:693)
    at gnu.expr.ApplyExp.compile(ApplyExp.java:244)
...

    -seth


On 12/19/2014 11:39 PM, Per Bothner wrote:


On 12/05/2014 03:49 PM, Seth Alves wrote:

It seems to be happening in FindCapturedVars.java line 274 in

   static Expression checkInlineable (LambdaExp current,
java.util.Set<LambdaExp> seen)
   {
    ...
             else if (r == null)
               {
                 r = t;
                 if (current.inlineHome == null)
current.inlineHome = current.nestedIn(p) ? p : p.inlineHome;
               }
    ...
    }


I checked in a fix for this. (I hope - I find this kind of code difficult.) Basically, I don't set inlineHome here, instead deferring doing so to visitLambdaExp.


#! /bin/sh
#| -*- scheme -*-
exec /usr/local/bin/kawa $0 "$@"
|#

(define-library (hmm)
  (export)
  (import (scheme base))
  (begin
    (define (blerg)
      (lambda (s) 
        (let loop ()
          (cond ((and #t (positive? 1))
                 (loop))
                (else #f)))))
    (define hmm (blerg))))


(import (scheme base)
        (scheme write))

(display "ok\n")

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]