|
View:
New views
1 Messages
—
Rating Filter:
Alert me
|
|
|
Re: Error detected while processing functionThanks a lot, I'll be checking out the new version, or updating to 7.
-- Aníbal Rojas http://www.rubycorner.com http://www.hasmanydevelopers.com On 2/26/07, vim-ruby-devel-request@... <vim-ruby-devel-request@...> wrote: > Send vim-ruby-devel mailing list submissions to > vim-ruby-devel@... > > To subscribe or unsubscribe via the World Wide Web, visit > http://rubyforge.org/mailman/listinfo/vim-ruby-devel > or, via email, send a message with subject or body 'help' to > vim-ruby-devel-request@... > > You can reach the person managing the list at > vim-ruby-devel-owner@... > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of vim-ruby-devel digest..." > > > Today's Topics: > > 1. Re: Error detected while processing function > <SNR>5_LoadFTPlugin: (Doug Kearns) > 2. Re: Error detected while processing function > <SNR>5_LoadFTPlugin: (Doug Kearns) > 3. Re: More syntax highlighting fun (Doug Kearns) > 4. Re: More syntax highlighting fun (Doug Kearns) > 5. Re: More syntax highlighting fun (Tim Pope) > 6. Re: More syntax highlighting fun (Tim Pope) > 7. Re: String interpolation highlighting (was Re: rubyFunction, > rubyClass, and rubyModule no longer highlighted) (Tim Pope) > 8. Re: String interpolation highlighting (was Re: rubyFunction, > rubyClass, and rubyModule no longer highlighted) (Nikolai Weibull) > 9. Re: String interpolation highlighting (was Re: rubyFunction, > rubyClass, and rubyModule no longer highlighted) (Tim Pope) > 10. Re: String interpolation highlighting (was Re: rubyFunction, > rubyClass, and rubyModule no longer highlighted) (Nikolai Weibull) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Mon, 26 Feb 2007 21:01:59 +1100 > From: Doug Kearns <dougkearns@...> > Subject: Re: Error detected while processing function > <SNR>5_LoadFTPlugin: > To: Vim-Ruby Devel ML <vim-ruby-devel@...> > Message-ID: <20070226100159.GC16545@...> > Content-Type: text/plain; charset=us-ascii > > On Sun, Feb 25, 2007 at 09:12:44PM -0600, Tim Pope wrote: > > <snip> > > > Speaking of which, Doug, any chance of finally doing that release in > > the next couple of release? The ERB indent file still hasn't seen the > > light of day yet. :) > > Oh that old chestnut. ;-) I was wondering about the status of > rubycomplete.vim which wasn't working for me at all. Since it now is, > for reasons unknown to me, it seems like a good idea. :) > > I just want to have a look through a patch to rubyunit.vim tonight. > > Regards, > Doug > > > ------------------------------ > > Message: 2 > Date: Mon, 26 Feb 2007 22:40:51 +1100 > From: Doug Kearns <dougkearns@...> > Subject: Re: Error detected while processing function > <SNR>5_LoadFTPlugin: > To: vim-ruby-devel@... > Message-ID: <20070226114051.GD16545@...> > Content-Type: text/plain; charset=iso-8859-1 > > G'day An?bal, > > On Sun, Feb 25, 2007 at 09:12:28PM -0400, An?bal Rojas wrote: > > Hello, > > > > I am quite new to vim. > > If you can, I'd suggest you update to the latest version Vim 7 for all > the usual reasons. > > <snip> > > > I am not sure if this is the correct place to write this message, > > please let me know if you would prefer this information being posted > > as a bug. > > Either here or the bug tracker is fine - what ever is easiest for you. > > Thanks, > Doug > > > ------------------------------ > > Message: 3 > Date: Tue, 27 Feb 2007 00:09:12 +1100 > From: Doug Kearns <dougkearns@...> > Subject: Re: More syntax highlighting fun > To: Vim-Ruby Devel ML <vim-ruby-devel@...> > Message-ID: <20070226130911.GE16545@...> > Content-Type: text/plain; charset=us-ascii > > On Thu, Feb 22, 2007 at 11:32:36AM -0600, Tim Pope wrote: > > <snip> > > > I also did a lot of clean-up, so let me know if you find anything that > > breaks. > > self isn't being highlighted in these two examples. > > class <<self > end > > class<<self > end > > <snip> > > Regards, > Doug > > > ------------------------------ > > Message: 4 > Date: Tue, 27 Feb 2007 00:31:28 +1100 > From: Doug Kearns <dougkearns@...> > Subject: Re: More syntax highlighting fun > To: Vim-Ruby Devel ML <vim-ruby-devel@...> > Message-ID: <20070226133128.GF16545@...> > Content-Type: text/plain; charset=us-ascii > > On Tue, Feb 27, 2007 at 12:09:12AM +1100, Doug Kearns wrote: > > <snip> > > > self isn't being highlighted in these two examples. > > > > class <<self > > end > > > > class<<self > > end > > I've fixed this with the following. Let me know if I'm overlooking > something. > > Regards, > Doug > > > Index: syntax/ruby.vim > =================================================================== > RCS file: /var/cvs/vim-ruby/vim-ruby/syntax/ruby.vim,v > retrieving revision 1.111 > diff -u -b -r1.111 ruby.vim > --- syntax/ruby.vim 26 Feb 2007 09:51:06 -0000 1.111 > +++ syntax/ruby.vim 26 Feb 2007 13:33:26 -0000 > @@ -155,8 +155,8 @@ > syn match rubyAliasDeclaration "[^[:space:];#.()]\+" contained contains=rubySymbol,rubyGlobalVariable,rubyPredefinedVariable nextgroup=rubyAliasDeclaration2 skipwhite > syn match rubyAliasDeclaration2 "[^[:space:];#.()]\+" contained contains=rubySymbol,rubyGlobalVariable,rubyPredefinedVariable > syn match rubyMethodDeclaration "[^[:space:];#(]\+" contained contains=rubyConstant,rubyBoolean,rubyPseudoVariable,rubyInstanceVariable,rubyClassVariable,rubyGlobalVariable > -syn match rubyClassDeclaration "[^[:space:];#(]\+" contained contains=rubyConstant > -syn match rubyModuleDeclaration "[^[:space:];#(]\+" contained contains=rubyConstant > +syn match rubyClassDeclaration "[^[:space:];#<]\+" contained contains=rubyConstant > +syn match rubyModuleDeclaration "[^[:space:];#]\+" contained contains=rubyConstant > syn match rubyFunction "\<[_[:alpha:]][_[:alnum:]]*[?!=]\=[[:alnum:].:?!=]\@!" contained containedin=rubyMethodDeclaration > syn match rubyFunction "\%(\s\|^\)\@<=[_[:alpha:]][_[:alnum:]]*[?!=]\=\%(\s\|$\)\@=" contained containedin=rubyAliasDeclaration,rubyAliasDeclaration2 > syn match rubyFunction "\%([[:space:].]\|^\)\@<=\%(\[\]=\=\|\*\*\|[+-]@\=\|[*/%|&^~]\|<<\|>>\|[<>]=\=\|<=>\|===\|==\|=\~\|`\)\%([[:space:];#(]\|$\)\@=" contained containedin=rubyAliasDeclaration,rubyAliasDeclaration2,rubyMethodDeclaration > > > ------------------------------ > > Message: 5 > Date: Mon, 26 Feb 2007 08:45:55 -0600 > From: Tim Pope <vim-ruby-devel@...> > Subject: Re: More syntax highlighting fun > To: Vim-Ruby Devel ML <vim-ruby-devel@...> > Message-ID: <20070226144555.GJ28979@...> > Content-Type: text/plain; charset=us-ascii > > On Tue, Feb 27, 2007 at 12:31:28AM +1100, Doug Kearns wrote: > > I've fixed this with the following. Let me know if I'm overlooking > > something. > > Exactly how I would have done it, thanks. > > Cheers, > Tim > > > ------------------------------ > > Message: 6 > Date: Mon, 26 Feb 2007 09:15:29 -0600 > From: Tim Pope <vim-ruby-devel@...> > Subject: Re: More syntax highlighting fun > To: Vim-Ruby Devel ML <vim-ruby-devel@...> > Message-ID: <20070226151529.GK28979@...> > Content-Type: text/plain; charset=us-ascii > > On Mon, Feb 26, 2007 at 08:57:17PM +1100, Doug Kearns wrote: > > On Sat, Feb 24, 2007 at 07:47:22PM -0600, Tim Pope wrote: > > > > <snip> > > > > > To further the original point, even the following is valid: > > > > > > def end; end > > > > > > Yes, end really can be a method name. So I'll be changing the pattern > > > to something like "\%(\<def\s\+\)\@<!\<end\>". This still doesn't fix > > > the indenting, but that's a much tougher nut to crack. > > > > I changed this to use \_s to allow for: > > > > def > > end > > end > > > > ...since we're being thorough. ;-) > > Actually, this omission was intentional. I figure if the end is on > the next line, the far more likely explanation is the user simply > hasn't typed the method name yet. But we can try it this way too. > > Cheers, > Tim > > > ------------------------------ > > Message: 7 > Date: Mon, 26 Feb 2007 09:21:40 -0600 > From: Tim Pope <vim-ruby-devel@...> > Subject: Re: String interpolation highlighting (was Re: rubyFunction, > rubyClass, and rubyModule no longer highlighted) > To: Vim-Ruby Devel ML <vim-ruby-devel@...> > Message-ID: <20070226152139.GL28979@...> > Content-Type: text/plain; charset=us-ascii > > On Mon, Feb 26, 2007 at 08:56:47PM +1100, Doug Kearns wrote: > > FWIW, I suspect that some of the highlighting will break when in an > > interpolation region since it makes assumptions about what can appear > > before and after syntax 'elements'. When I wrote these I didn't do so > > with this new addition in mind. Have you come across any yet? > > No, but it didn't take much searching: > > "#{if true then 1 end}" > > However, syntax highlighting also fails on > > 3.times { if true then 1 end } > > Of these two, the latter is more serious because it affects future end > highlighting. > > Adding { to the monster regexp setting off if/unless does not fix > this. Apparently Vim doesn't like backtracking through the beginning > of a region definition. I'll investigate a bit more; let me know if > you have any ideas. > > Cheers, > Tim > > > ------------------------------ > > Message: 8 > Date: Mon, 26 Feb 2007 17:44:56 +0100 > From: "Nikolai Weibull" <now@...> > Subject: Re: String interpolation highlighting (was Re: rubyFunction, > rubyClass, and rubyModule no longer highlighted) > To: "Vim-Ruby Devel ML" <vim-ruby-devel@...> > Message-ID: > <dbfc82860702260844j8d4232cy24c8bc3c5d4e1059@...> > Content-Type: text/plain; charset=ISO-8859-1; format=flowed > > On 2/26/07, Tim Pope <vim-ruby-devel@...> wrote: > > On Mon, Feb 26, 2007 at 08:56:47PM +1100, Doug Kearns wrote: > > > FWIW, I suspect that some of the highlighting will break when in an > > > interpolation region since it makes assumptions about what can appear > > > before and after syntax 'elements'. When I wrote these I didn't do so > > > with this new addition in mind. Have you come across any yet? > > > > No, but it didn't take much searching: > > > > "#{if true then 1 end}" > > > > However, syntax highlighting also fails on > > > > 3.times { if true then 1 end } > > > > Of these two, the latter is more serious because it affects future end > > highlighting. > > > > Adding { to the monster regexp setting off if/unless does not fix > > this. Apparently Vim doesn't like backtracking through the beginning > > of a region definition. I'll investigate a bit more; let me know if > > you have any ideas. > > Uh, oh. It sounds as if we're going overboard here. Sorry, no ideas, > just complaints. Still, it's going to be very hard to match every > weird part of the Ruby grammar, so optimizing for the common cases > makes things a lot easier. I'm sure there's code out there that > actually contains the line "#{if true then 1 end}", but I don't see > why we should try so damn hard to match it beyond matching the > delimiters. If you're silly enough to put a lot of junk in your > string interpolations, then syntax highlighting isn't really going to > help you much. > > nikolai > > > ------------------------------ > > Message: 9 > Date: Mon, 26 Feb 2007 12:59:04 -0600 > From: Tim Pope <vim-ruby-devel@...> > Subject: Re: String interpolation highlighting (was Re: rubyFunction, > rubyClass, and rubyModule no longer highlighted) > To: Vim-Ruby Devel ML <vim-ruby-devel@...> > Message-ID: <20070226185904.GN28979@...> > Content-Type: text/plain; charset=us-ascii > > On Mon, Feb 26, 2007 at 05:44:56PM +0100, Nikolai Weibull wrote: > > On 2/26/07, Tim Pope <vim-ruby-devel@...> wrote: > > > On Mon, Feb 26, 2007 at 08:56:47PM +1100, Doug Kearns wrote: > > > > FWIW, I suspect that some of the highlighting will break when in an > > > > interpolation region since it makes assumptions about what can appear > > > > before and after syntax 'elements'. When I wrote these I didn't do so > > > > with this new addition in mind. Have you come across any yet? > > > > > > No, but it didn't take much searching: > > > > > > "#{if true then 1 end}" > > > > > > However, syntax highlighting also fails on > > > > > > 3.times { if true then 1 end } > > > > > > Of these two, the latter is more serious because it affects future end > > > highlighting. > > > > > > Adding { to the monster regexp setting off if/unless does not fix > > > this. Apparently Vim doesn't like backtracking through the beginning > > > of a region definition. I'll investigate a bit more; let me know if > > > you have any ideas. > > > > Uh, oh. It sounds as if we're going overboard here. Sorry, no ideas, > > just complaints. Still, it's going to be very hard to match every > > weird part of the Ruby grammar, so optimizing for the common cases > > makes things a lot easier. I'm sure there's code out there that > > actually contains the line "#{if true then 1 end}", but I don't see > > why we should try so damn hard to match it beyond matching the > > delimiters. If you're silly enough to put a lot of junk in your > > string interpolations, then syntax highlighting isn't really going to > > help you much. > > Agreed, regarding strings. However, I thing my second example, > > 3.times { if true then 1 end } > > is a bit more reasonable. A fix for this would probably fix the > string interpolation for free. > > Cheers, > Tim > > > ------------------------------ > > Message: 10 > Date: Mon, 26 Feb 2007 21:15:06 +0100 > From: "Nikolai Weibull" <now@...> > Subject: Re: String interpolation highlighting (was Re: rubyFunction, > rubyClass, and rubyModule no longer highlighted) > To: "Vim-Ruby Devel ML" <vim-ruby-devel@...> > Message-ID: > <dbfc82860702261215q4f565f2h2968065bfc5b2478@...> > Content-Type: text/plain; charset=ISO-8859-1; format=flowed > > On 2/26/07, Tim Pope <vim-ruby-devel@...> wrote: > > On Mon, Feb 26, 2007 at 05:44:56PM +0100, Nikolai Weibull wrote: > > > On 2/26/07, Tim Pope <vim-ruby-devel@...> wrote: > > > > On Mon, Feb 26, 2007 at 08:56:47PM +1100, Doug Kearns wrote: > > > > > FWIW, I suspect that some of the highlighting will break when in an > > > > > interpolation region since it makes assumptions about what can appear > > > > > before and after syntax 'elements'. When I wrote these I didn't do so > > > > > with this new addition in mind. Have you come across any yet? > > > > > > > > No, but it didn't take much searching: > > > > > > > > "#{if true then 1 end}" > > > > > > > > However, syntax highlighting also fails on > > > > > > > > 3.times { if true then 1 end } > > > > > > > > Of these two, the latter is more serious because it affects future end > > > > highlighting. > > > > > > > > Adding { to the monster regexp setting off if/unless does not fix > > > > this. Apparently Vim doesn't like backtracking through the beginning > > > > of a region definition. I'll investigate a bit more; let me know if > > > > you have any ideas. > > > > > > Uh, oh. It sounds as if we're going overboard here. Sorry, no ideas, > > > just complaints. Still, it's going to be very hard to match every > > > weird part of the Ruby grammar, so optimizing for the common cases > > > makes things a lot easier. I'm sure there's code out there that > > > actually contains the line "#{if true then 1 end}", but I don't see > > > why we should try so damn hard to match it beyond matching the > > > delimiters. If you're silly enough to put a lot of junk in your > > > string interpolations, then syntax highlighting isn't really going to > > > help you much. > > > > Agreed, regarding strings. However, I thing my second example, > > > > 3.times { if true then 1 end } > > > > is a bit more reasonable. A fix for this would probably fix the > > string interpolation for free. > > Absolutely. I don't know if it fixes it, but that would be good too ;-). > > Wait, this only fails if you have that silly "what-type-of-end-is-it" > option on, right? > > nikolai > > > ------------------------------ > > _______________________________________________ > vim-ruby-devel mailing list > vim-ruby-devel@... > http://rubyforge.org/mailman/listinfo/vim-ruby-devel > > End of vim-ruby-devel Digest, Vol 33, Issue 7 > ********************************************* > vim-ruby-devel mailing list vim-ruby-devel@... http://rubyforge.org/mailman/listinfo/vim-ruby-devel |
| Free embeddable forum powered by Nabble | Forum Help |