68579Re: [PATCH] add 'cinoption' "E" to correctly indent enum for Java code
- Mar 5, 2013On Mar 5, 2013, at 11:57 AM, Bram Moolenaar <Bram@...> wrote:
>I tried without the patch, but they cannot pass on my computer... This
> Hong Xu wrote:
>> On Tuesday, March 5, 2013 8:16:48 AM UTC-8, Lech Lorens wrote:
>>> Wouldn't it be better to use the existing 'cinoptions' entry jN? It's
>>> related to Java...
>>> BTW, in the past I made a number of modifications to the indenting
>>> code. It was like treading on a mine field (lots of things I could
>>> break). Would you, please, also include a test case for your
>>> functionality so that the next person that modifies get_c_indent()
>>> does not break what you've achieved?
>> Thanks for the reminder. I have included the test case in the new
>> attached patch.
> Thanks, tests are good. However, it seems the test passes without your
> "static" is already checked for and skipped above the lines you insert.We do need the second check inside the loop, since people may write either:
> Without a flag to enable this. I don't see much of a problem also
> skipping the public/private/protected attributes without a flag.
public static enum
static public enum
Yes, I do agree with you about the flag to enable this. We really don't
need any flags to enable this since nothing is messed up with this
additional feature. I attached a new patch here, with updated code and
an updated test.
> Actually, what really matters is the check for "=". I think it shouldI tried to add a flag here, but it seems the 'J' option is broken in
> be ignored for Java, the "j" flag.
this way (test3 would fail).
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
You received this message because you are subscribed to the Google Groups "vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
For more options, visit https://groups.google.com/groups/opt_out.
- << Previous post in topic Next post in topic >>