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.

Bug 150319 - IllegalArgumentException: indent=-7 < 0
Summary: IllegalArgumentException: indent=-7 < 0
Status: STARTED
Alias: None
Product: contrib
Classification: Unclassified
Component: Scala (show other bugs)
Version: 6.x
Hardware: PC Windows XP
: P3 blocker (vote)
Assignee: _ dcaoyuan
URL: http://statistics.netbeans.org/except...
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-16 06:32 UTC by misterm
Modified: 2009-05-19 11:57 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 120997


Attachments
stacktrace (3.48 KB, text/plain)
2008-10-16 20:12 UTC, misterm
Details
stacktrace (3.48 KB, text/plain)
2008-12-07 19:28 UTC, buzzword
Details

Note You need to log in before you can comment on or make changes to this bug.
Description misterm 2008-10-16 06:32:42 UTC
Build: NetBeans IDE Dev (Build 200809300201)
VM: Java HotSpot(TM) Client VM, 10.0-b23, Java(TM) SE Runtime Environment, 1.6.0_07-b06
OS: Windows Vista, 6.0, x86
User comments: 
STACKTRACE: (first 10 lines)
java.lang.IllegalArgumentException: indent=-7 < 0
        at org.netbeans.modules.editor.indent.api.IndentUtils.createIndentString(IndentUtils.java:200)
        at org.netbeans.modules.editor.indent.spi.Context.modifyIndent(Context.java:177)
        at org.netbeans.modules.scala.editing.ScalaFormatter$1.run(ScalaFormatter.java:310)
        at org.netbeans.editor.GuardedDocument.runAtomic(GuardedDocument.java:294)
        at org.netbeans.modules.scala.editing.ScalaFormatter.reindent(ScalaFormatter.java:267)
        at org.netbeans.modules.scala.editing.ScalaFormatter.reindent(ScalaFormatter.java:140)
        at org.netbeans.modules.gsf.GsfIndentTask.reindent(GsfIndentTask.java:69)
        at org.netbeans.modules.editor.indent.TaskHandler$MimeItem.runTask(TaskHandler.java:502)
        at org.netbeans.modules.editor.indent.TaskHandler.runTasks(TaskHandler.java:271)
        at org.netbeans.modules.editor.indent.IndentImpl.reindent(IndentImpl.java:232)
Comment 1 misterm 2008-10-16 20:12:31 UTC
Created attachment 72033 [details]
stacktrace
Comment 2 buzzword 2008-12-07 19:27:50 UTC
Build: NetBeans IDE Dev (Build 200811260201)
VM: Java HotSpot(TM) Client VM, 11.0-b15, Java(TM) SE Runtime Environment, 1.6.0_10-b33
OS: Windows XP, 5.1, x86

User Comments: 
Writing scala code. Pressing enter to define a new lazy val in an object.

Stacktrace: 
java.lang.IllegalArgumentException: indent=-8 < 0
        at org.netbeans.modules.editor.indent.api.IndentUtils.createIndentString(IndentUtils.java:200)
        at org.netbeans.modules.editor.indent.spi.Context.modifyIndent(Context.java:177)
        at org.netbeans.modules.scala.editing.ScalaFormatter$1.run(ScalaFormatter.java:310)
        at org.netbeans.editor.GuardedDocument.runAtomic(GuardedDocument.java:294)
        at org.netbeans.modules.scala.editing.ScalaFormatter.reindent(ScalaFormatter.java:267)
        at org.netbeans.modules.scala.editing.ScalaFormatter.reindent(ScalaFormatter.java:140)
Comment 3 buzzword 2008-12-07 19:28:00 UTC
Created attachment 74663 [details]
stacktrace
Comment 4 Exceptions Reporter 2009-04-23 21:06:57 UTC
This issue already has 10 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=120997
Comment 5 _ dcaoyuan 2009-05-19 11:57:57 UTC
Quick fix: rev/48024b4d0178