Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Allowing explicit :line metadata to pass unharmed
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  3 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Chas Emerick  
View profile  
 More options Sep 29 2012, 8:14 pm
From: Chas Emerick <c...@cemerick.com>
Date: Sat, 29 Sep 2012 20:14:47 -0400
Local: Sat, Sep 29 2012 8:14 pm
Subject: Allowing explicit :line metadata to pass unharmed
I've filed a new issue, CLJ-1079:

http://dev.clojure.org/jira/browse/CLJ-1079

In short, this changes the reader slightly to ensure that explicit :line metadata in loaded code is used in preference to line numbers provided by a LineNumberingPushbackReader, if one is being used.  More details and context are in the issue description, but here's a quick REPL demonstration illustrating the problem:

=> (meta (read (clojure.lang.LineNumberingPushbackReader.
                 (java.io.StringReader. "^{:line 66} ()"))))
{:line 1}

...this is in contrast to the (correct, IMO) behaviour when one does not use a LineNumberingPushbackReader (this is essentially what read-string does):

=> (meta (read (java.io.PushbackReader.
                 (java.io.StringReader. "^{:line 66} ()"))))
{:line 66}

The patch attached to the issue is minor IMO, but I wanted to open a thread here as well; I seem to remember this being a topic at some point in the past, but I couldn't find that discussion.

Cheers,

- Chas


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Chas Emerick  
View profile  
 More options Oct 5 2012, 10:28 am
From: Chas Emerick <c...@cemerick.com>
Date: Fri, 5 Oct 2012 10:28:02 -0400
Local: Fri, Oct 5 2012 10:28 am
Subject: Re: Allowing explicit :line metadata to pass unharmed
The recent addition of :column metadata to the reader and such (great addition, BTW!) made it so the patch for this no longer applied cleanly.

I've since tweaked the patch to make it apply, and extended the treatment of :line metadata to :column as well:

http://dev.clojure.org/jira/browse/CLJ-1079

I'd love to get this screened, if anyone has a minute today.

Thanks,

- Chas

On Sep 29, 2012, at 8:14 PM, Chas Emerick wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Chas Emerick  
View profile  
 More options Dec 7 2012, 11:43 am
From: Chas Emerick <c...@cemerick.com>
Date: Fri, 7 Dec 2012 11:43:43 -0500
Local: Fri, Dec 7 2012 11:43 am
Subject: Re: Allowing explicit :line metadata to pass unharmed
Bump: http://dev.clojure.org/jira/browse/CLJ-1079 :-P

The screening and application of the patch there would make life quite a bit easier when attempting to write portable Clojure/ClojureScript using the best tools that exist currently.  (The patch still applies cleanly as of this morning.)  I responded to Stu H's last comment on the ticket, and would love to get this to the next step (even if that's a further dialogue).

Cheers,

- Chas

On Oct 5, 2012, at 10:28 AM, Chas Emerick wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »