bugKawa - Bugs: bug #17993, Unbound location exception when...

 
 

bug #17993: Unbound location exception when require-d syntax calls some procedures

Submitted by:  Chris Wegrzyn <cwegrzyn>
Submitted on:  Fri 13 Oct 2006 07:17:15 PM UTC  
 
Category: Scheme languageSeverity: 3 - Normal
Item Group: Run-time exceptionStatus: Fixed
Privacy: PublicAssigned to: Per Bothner <bothner>
Open/Closed: Closed

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Tue 17 Oct 2006 03:59:46 PM UTC, comment #4:

I checked in the attached patch.

Per Bothner <bothner>
Project AdministratorIn charge of this item.
Mon 16 Oct 2006 01:22:07 PM UTC, comment #3:

Compiling with --module-static does seem to resolve the problem for me. For the time being, it's the only solution I need.

Chris Wegrzyn <cwegrzyn>
Sat 14 Oct 2006 06:58:56 PM UTC, comment #2:

I have a rough patch, but it's a bit ugly, and I want to consider alternatives.

Per Bothner <bothner>
Project AdministratorIn charge of this item.
Sat 14 Oct 2006 01:44:24 AM UTC, comment #1:

My reaction was: Huh? But I have tests for this.
And indeed it works if brokensyntax-test.scm is also compiled.

It also works if brokensyntax.scm is compiled using the --module-static flag.

Otherwise, we get a NullPointerException because the ReferenceExp's contextDecl() is null. More later.

Per Bothner <bothner>
Project AdministratorIn charge of this item.
Fri 13 Oct 2006 07:17:15 PM UTC, original submission:

Syntax definitions (using define-syntax) that are loaded into the current environment from compiled scheme classes with require (or programmatically with loadClass) cause an "unbound location exception" when they expand to calls to functions defined in the same scope as the syntax definition. The problem only occurs when the function that is called by the syntax refers to other defined values. For example, in the attached testcase, replacing the identifier foobar with the string "foobar" fixes the problem.

I have attached two scheme files that make up a testcase for this problem. To reproduce the problem, compile brokensyntax.scm (kawa -C) and then run brokensyntax-test.scm (kawa -f). I haven't had time yet to figure out a fix for this problem. I have tested this against r5524.

Chris Wegrzyn <cwegrzyn>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #10988:  17993.patch added by bothner (3KiB - text/x-patch - Patch)
file #10968:  brokensyntax-test.scm added by cwegrzyn (500B - application/octet-stream - testcase: file to run)
file #10967:  brokensyntax.scm added by cwegrzyn (246B - application/octet-stream - testcase: file to compile)

 

Depends on the following items: None found

Items that depend on this one: None found

 

CC list is empty

 

Do you think this task is very important?
If so, you can click here to add your encouragement to it.
This task has 0 encouragements so far.

Only logged-in users can vote.

 

Please enter the title of George Orwell's famous dystopian book (it's a date):

 

 

Follow 7 latest changes.

Date Changed By Updated Field Previous Value => Replaced By
Tue 17 Oct 2006 03:59:46 PM UTCbothnerStatusConfirmed=>Fixed
  Open/ClosedOpen=>Closed
  Attached File-=>Added 17993.patch, #10988
Sat 14 Oct 2006 01:44:49 AM UTCbothnerStatusNone=>Confirmed
  Assigned toNone=>bothner
Fri 13 Oct 2006 07:20:24 PM UTCcwegrzynAttached File-=>Added brokensyntax-test.scm, #10968
Fri 13 Oct 2006 07:17:15 PM UTCcwegrzynAttached File-=>Added brokensyntax.scm, #10967

Back to the top


Powered by Savane 3.1-cleanup1