newlisp.vim 1.35

Started by Cyril, April 15, 2011, 12:11:23 AM

Previous topic - Next topic

Cyril

I've just realized that I haven't visited this forum for a half-year now. I am still using newLISP, just feeling less social about it. ;-) And now is the time for a new version of the syntax highlighter for the Vim text editor. This version is highly experimental, testing and feedback is highly appreciated. User-visible changes:



* String delimiters ("quotes", {braces}, and [text]tokens[/text]) are highlighted in different color than the string content.



* Bracketed symbols [like this] are highlighted in boldface; no other symbols are highlighted in boldface anymore (the newlispSymbolSpecial group is gone).



* Errors highlighting is drastically changed. The newLISP itself allows tokens to touch without  a separator, this leads to very strange code in some cases. For example, 019 is two tokens, not one (digit nine may not occur in octal literal, so it starts a fresh new number). Similarly, one[two] is one single token, but [one]two are two (check this with your newLISP interpreter!). I believe that using this feature in the real code leads to confusion, therefore the adjacent tokens are marked as errors (to be precise, the second of two adjacent tokens is marked as error, this should give you a clue why there are two and not one!). You can see some corner case examples http://slobin.pp.ru/newlisp/errors.lsp.html">here.



Downloadable from the usual locations (http://www.vim.org/scripts/script.php?script_id=2067">one, http://slobin.pp.ru/vim/syntax/newlisp.vim">two). And again, this is an experimental version, please test it before using in production!
With newLISP you can grow your lists from the right side!

cormullion

#1
I've been using vim recently and your newlisp.vim file is working fine. But I'm downloading your latest version and will tell you of any problems. Usually, with vim, I assume I've done something wrong (it's not the easiest software to become a master of), so you may not get many bug reports...

TedWalther

#2
I like using vim.  Can you explain something?



I like to have "autoindent" like in emacs.  Is there a way to turn this on?



The horrible indenting behavior is making me flip flop between vim and emacs; vim for editing, emacs for formatting!



Now, admittedly, I'd like tabs longer than 2 spaces deep.  4 would be plenty. And I would like dragonfly style for close braces.



Can your vim mode do this?
Cavemen in bearskins invaded the ivory towers of Artificial Intelligence.  Nine months later, they left with a baby named newLISP.  The women of the ivory towers wept and wailed.  \"Abomination!\" they cried.

TedWalther

#3
I especially like that in emacs, I hit tab anywhere on the line, and it just correctly indents the whole line.
Cavemen in bearskins invaded the ivory towers of Artificial Intelligence.  Nine months later, they left with a baby named newLISP.  The women of the ivory towers wept and wailed.  \"Abomination!\" they cried.

kanen

#4
I've been writing code with your updated newlisp.vim since you posted in this thread.



I shared a screen shot of my vim terminal in another thread, but thought you'd want to see it here.



MacVim (plus a bunch of extras installed).



http://www.lifezero.org/storage/mvim.png">
. Kanen Flowers http://kanen.me[/url] .

TedWalther

#5
Kanen, did you get auto-indent to work, or did you indent your code by hand?  It looks nicely formatted, like how I want it.
Cavemen in bearskins invaded the ivory towers of Artificial Intelligence.  Nine months later, they left with a baby named newLISP.  The women of the ivory towers wept and wailed.  \"Abomination!\" they cried.