Feature #127

Clojure Scanner

Added by Kornelius Kalnbach 11 months ago. Updated about 1 month ago.

Status:New Start:10/04/2009
Priority:Normal Due date:
Assigned to:Heinz Gies % Done:

80%

Category:Scanner requests
Target version:1.0 RC1

Description

A nice new language, maybe licenser can help with the implementation.

Example code is already in the repo.

clojure.rb (8.1 KB) Heinz Gies, 06/14/2010 02:29 am

epic.in.clj (34.7 KB) Heinz Gies, 06/14/2010 02:29 am

clj-swing.in.clj (21.7 KB) Heinz Gies, 06/14/2010 02:29 am

clj-highlight.in.clj (18.3 KB) Heinz Gies, 06/14/2010 02:29 am

clicky.in.clj (2.9 KB) Heinz Gies, 06/14/2010 02:29 am

swing.in.clj (3.1 KB) Heinz Gies, 06/14/2010 02:29 am

Associated revisions

Revision 600
Added by Kornelius Kalnbach 3 months ago

Ticket #127: Clojure scanner by Licenser, yay!

It's still in development. The Scheme scanner, which Lice used as template,
has some very bad code, and both scanner must be cleaned up (see #59).

History

Updated by Kornelius Kalnbach 11 months ago

  • Tracker changed from Bug to Feature

Updated by Kornelius Kalnbach 11 months ago

  • Target version set to 1.1

Updated by Kornelius Kalnbach 8 months ago

  • Assigned to changed from Kornelius Kalnbach to Heinz Gies

Updated by Kornelius Kalnbach 6 months ago

We really need this :)

Updated by Heinz Gies 4 months ago

  • File clojure.rb added

So a first version based on the Scheme scanner.

Updated by Kornelius Kalnbach 4 months ago

Thank you!

But I'm sorry, I am just now completely changing the Tokens API ;) I've already rewritten all the supported scanners, but I'll be updating yours for free because you couldn't know.

You said there were some problems when you implemented this? Can you elaborate?

Also, we need lots and lots of test code.

Updated by Heinz Gies 4 months ago

  • % Done changed from 0 to 50

Update that takes care of clojuresq function names.

http://blog.licenser.net/files/clojure.rb

Updated by Kornelius Kalnbach 4 months ago

  • Target version changed from 1.1 to 1.0 RC1

Updated by Heinz Gies 3 months ago

  • File clojure.rb added

A Mostly correct version:

Updated by Heinz Gies 3 months ago

  • File clojure.rb added
  • % Done changed from 50 to 80

Some more cleanup

Updated by Heinz Gies 3 months ago

  • File deleted (clojure.rb)

Updated by Heinz Gies 3 months ago

  • File deleted (clojure.rb)

Updated by Heinz Gies 3 months ago

  • File deleted (clojure.rb)

Updated by Heinz Gies 3 months ago

Test and an example scanner are here:

Updated by Kornelius Kalnbach 2 months ago

A list of functions annd macros: http://clojure.org/cheatsheet

Updated by Heinz Gies 2 months ago

Kornelius Kalnbach wrote:

A list of functions annd macros: http://clojure.org/cheatsheet

I'm not certain if this is the entire list of core macros and functions. http://richhickey.github.com/clojure/index.html should be more complete.

Updated by josh cheek about 1 month ago

Hi. I need Clojure highlighting, I am using it with Kramdown, is there a walkthrough somewhere for how I could use the above work in my project?

Updated by Heinz Gies about 1 month ago

josh cheek wrote:

Hi. I need Clojure highlighting, I am using it with Kramdown, is there a walkthrough somewhere for how I could use the above work in my project?

Coderay is a library so it is fairly easy, you can see the API documentation here http://coderay.rubychan.de/doc/ it also includes some code examples, if you plan to write stuff in clojure there is also a clojure highlighter in clojure, clj-highlight, so coderay is currently faster and better I'd say.

Regards,
Heinz

Updated by Kornelius Kalnbach about 1 month ago

josh cheek wrote:

Hi. I need Clojure highlighting, I am using it with Kramdown, is there a walkthrough somewhere for how I could use the above work in my project?

Never heard of kramdown before, but since it's a Ruby library, it should be as easy as putting a require 'my-clojure-scanner' somewhere after CodeRay was loaded.

Updated by josh cheek about 1 month ago

Wow, that was extremely easy. Thanks.

Updated by Kornelius Kalnbach about 1 month ago

Cool :) You're welcome.

Also available in: Atom PDF