This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Currently "end" is automatically inserted when missing from block-opening tokens like if, do, case, class, etc. However, there are usecases when it should be inserted after top-level (but not opening) tokens like, else, elseif, rescue, etc. See discussion from dev@scripting.netbeans.org: From: charles.nutter@sun.com Subject: Re: if...else...end and begin...rescue..end completion Date: March 30, 2007 9:05:46 AM PDT To: dev@scripting.netbeans.org Reply-To: dev@scripting.netbeans.org Tor Norbye wrote: > I'm sorry, I didn't really follow this. Can you explain again what it is you expect would happen? > The way it works now is that if you type "if" and hit enter, you end up with > if foo > | > end > you can then type else - and it will automatically reindent the line to align with "if" as soon as you type the final "e" in else. > (If you keep typing, let's say elseq = 50" it will immediately (on the next keystroke) move indentation back the way it was.) >What was it you were expecting or would like to see? What I expected was that if I backspaced out end and typed else, it would undent it and add a new end for me. Oddly, that's what seemed to me, since if I have an existing if...end and want to add an else, I tend to kill the end and start a new else block. Maybe a personal quirk? Anyway, I did try it your way and I must say I think I may like it better. But I'm only one person...it wasn't immediately intuitive to me that I would add an "else" in the middle of my "if" block, though I like that it works so well. - Charlie
Reassigning this issue to newly created 'ruby' component.
This is really edge-case, might be not worth to fix? Rather RFE. Nobody ever complains about it - except Charles, who is now surely used to the editor workflow ;)
This bug was reported against NetBeans IDE 6.0 or an older release, or against a non-maintained module. NetBeans team does not have enough resources to get to this issue, therefore we are closing the issue as a WONTFIX. If you are interested in providing a patch for this bug, please see our NetFIX guidelines for how to proceed. We apologize for any inconvenience. Thank you. The NetBeans Team