[ jEdit-users ] Clojure parenthesis matching broken in 5.4

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

[ jEdit-users ] Clojure parenthesis matching broken in 5.4

Jarvis, Bob-2


I notice that in 5.4 the parenthesis matching for Clojure seems to have become broken. I believe it worked fine in 5.1, which I was using until recently. In particular, if the “*” function (multiplication) is invoked in a manner similar to

 

                (* 1 2 3)

 

the closing right-paren at the end of the form won’t be matched to the opening left-paren before the “*”. If the * is replaced with anything else the parenthesis matching again works correctly, so this seems to be something specifically related to how “*” is handled. If a second “*” is added the matching will again work properly. Not having parenthesis matching working properly is a royal pain for programming in any Lisp variant so a fix would be very helpful.

 

Not sure where to look to fix this. Any ideas or hints appreciated.

 

Thanks,

Bob

 

cid:ii_14b3b7f7ec8d3ab3
Bob Jarvis
Senior Programming Analyst
[hidden email]

p 330.665.6056  | 375 Ghent Rd.

f  330.665.6266  | Akron, OH 44333

 



The information contained in this e-mail message is privileged and/or confidential and is intended only for the use of the individual or entity named above. If the reader of this message is not the intended recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communications in error, please immediately notify us by telephone (330-668-5000), and destroy the original message. Thank you.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Users' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-users
Reply | Threaded
Open this post in threaded view
|

Re: [ jEdit-users ] Clojure parenthesis matching broken in 5.4

Dale Anson-3
It looks like this problem was caused by a change in the clojure mode file that was made quite a while ago. I don't know clojure at all, but if I change the mode file to move lines 41 through 44 to just after line 797, the parenthesis works correctly. You can find the mode file by going to Utilities - jEdit Home Directory - Modes, this should open the jEdit file browser to the directory containing the mode files. Find clojure.xml, open it, and cut lines 41 - 44, they look like this:

        <SPAN TYPE="KEYWORD4" DELEGATE="MAIN">
            <BEGIN>*</BEGIN>
            <END>*</END>
        </SPAN>

then paste them at line 798, just following this line:

<KEYWORD4>*state*</KEYWORD4>

jEdit should pick up the change right away, but if not, you can go to Utilities - Troubleshooting - Reload Edit Modes to have jEdit pick up the change.

It would be nice if someone who knows clojure well could verify that this is an appropriate fix.

Dale







On Thu, May 4, 2017 at 8:55 AM, Jarvis, Bob <[hidden email]> wrote:


I notice that in 5.4 the parenthesis matching for Clojure seems to have become broken. I believe it worked fine in 5.1, which I was using until recently. In particular, if the “*” function (multiplication) is invoked in a manner similar to

 

                (* 1 2 3)

 

the closing right-paren at the end of the form won’t be matched to the opening left-paren before the “*”. If the * is replaced with anything else the parenthesis matching again works correctly, so this seems to be something specifically related to how “*” is handled. If a second “*” is added the matching will again work properly. Not having parenthesis matching working properly is a royal pain for programming in any Lisp variant so a fix would be very helpful.

 

Not sure where to look to fix this. Any ideas or hints appreciated.

 

Thanks,

Bob

 

cid:ii_14b3b7f7ec8d3ab3
Bob Jarvis
Senior Programming Analyst
[hidden email]

p <a href="tel:(330)%20665-6056" value="+13306656056" target="_blank">330.665.6056  | 375 Ghent Rd.

f  <a href="tel:(330)%20665-6266" value="+13306656266" target="_blank">330.665.6266  | Akron, OH 44333

 



The information contained in this e-mail message is privileged and/or confidential and is intended only for the use of the individual or entity named above. If the reader of this message is not the intended recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communications in error, please immediately notify us by telephone <a href="tel:(330)%20668-5000" value="+13306685000" target="_blank">(330-668-5000), and destroy the original message. Thank you.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Users' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-users



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Users' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-users
Reply | Threaded
Open this post in threaded view
|

Re: [ jEdit-users ] Clojure parenthesis matching broken in 5.4

Jarvis, Bob-2


Dale – thanks for the help.

 

Moving the block in question didn’t fix the highlighting for me, despite completely exiting jEdit and shutting down the server. Instead, I commented that block out of the mode file, at which point the parenthesis matching began working as expected again.

 

I would not describe myself as a “Clojure expert” but I’ll take a look at the mode file.

 

Thanks,

Bob

 

cid:ii_14b3b7f7ec8d3ab3
Bob Jarvis
Senior Programming Analyst
[hidden email]

p 330.665.6056  | 375 Ghent Rd.

f  330.665.6266  | Akron, OH 44333

 

From: [hidden email] [mailto:[hidden email]] On Behalf Of Dale Anson
Sent: Thursday, May 04, 2017 11:51 AM
To: Jarvis, Bob <[hidden email]>
Cc: jedit-users <[hidden email]>
Subject: Re: [ jEdit-users ] Clojure parenthesis matching broken in 5.4

 

It looks like this problem was caused by a change in the clojure mode file that was made quite a while ago. I don't know clojure at all, but if I change the mode file to move lines 41 through 44 to just after line 797, the parenthesis works correctly. You can find the mode file by going to Utilities - jEdit Home Directory - Modes, this should open the jEdit file browser to the directory containing the mode files. Find clojure.xml, open it, and cut lines 41 - 44, they look like this:

 

        <SPAN TYPE="KEYWORD4" DELEGATE="MAIN">

            <BEGIN>*</BEGIN>

            <END>*</END>

        </SPAN>

 

then paste them at line 798, just following this line:

 

<KEYWORD4>*state*</KEYWORD4>

 

jEdit should pick up the change right away, but if not, you can go to Utilities - Troubleshooting - Reload Edit Modes to have jEdit pick up the change.

 

It would be nice if someone who knows clojure well could verify that this is an appropriate fix.

 

Dale

 

 

 

 

 

 

 

On Thu, May 4, 2017 at 8:55 AM, Jarvis, Bob <[hidden email]> wrote:

 

I notice that in 5.4 the parenthesis matching for Clojure seems to have become broken. I believe it worked fine in 5.1, which I was using until recently. In particular, if the “*” function (multiplication) is invoked in a manner similar to

 

                (* 1 2 3)

 

the closing right-paren at the end of the form won’t be matched to the opening left-paren before the “*”. If the * is replaced with anything else the parenthesis matching again works correctly, so this seems to be something specifically related to how “*” is handled. If a second “*” is added the matching will again work properly. Not having parenthesis matching working properly is a royal pain for programming in any Lisp variant so a fix would be very helpful.

 

Not sure where to look to fix this. Any ideas or hints appreciated.

 

Thanks,

Bob

 

cid:ii_14b3b7f7ec8d3ab3
Bob Jarvis
Senior Programming Analyst
[hidden email]

p <a href="tel:(330)%20665-6056" target="_blank">330.665.6056  | 375 Ghent Rd.

f  <a href="tel:(330)%20665-6266" target="_blank">330.665.6266  | Akron, OH 44333

 



The information contained in this e-mail message is privileged and/or confidential and is intended only for the use of the individual or entity named above. If the reader of this message is not the intended recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communications in error, please immediately notify us by telephone <a href="tel:(330)%20668-5000" target="_blank">(330-668-5000), and destroy the original message. Thank you.


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Users' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-users

 



The information contained in this e-mail message is privileged and/or confidential and is intended only for the use of the individual or entity named above. If the reader of this message is not the intended recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communications in error, please immediately notify us by telephone (330-668-5000), and destroy the original message. Thank you.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
--
-----------------------------------------------
jEdit Users' List
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jedit-users