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 67761

Summary: ClassCastException: org.openide.text.PositionRef$Manager$OffsetKind
Product: platform Reporter: bonej010 <bonej010>
Component: TextAssignee: Denis Anisimov <ads>
Status: RESOLVED FIXED    
Severity: blocker CC: mroskanin
Priority: P3    
Version: 5.x   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter:
Attachments: Message.log

Description bonej010 2005-10-29 09:32:18 UTC
I get this error frequently in the editor - unfortunately there is no noticable
pattern, except that it happens perhaps when scrolling after inserting some
code, but it may also be something totally different:

java.lang.ClassCastException: org.openide.text.PositionRef$Manager$OffsetKind
	at org.openide.text.PositionRef.getPosition(PositionRef.java:122)
	at org.openide.text.DocumentLine$Part.addAnnotation(DocumentLine.java:672)
	at org.openide.text.Annotation.attach(Annotation.java:85)
	at pmd.scan.Scanner.run(Scanner.java:141)
[catch] at java.lang.Thread.run(Thread.java:595)

Cheers
Joseph
Comment 1 bonej010 2005-10-29 09:33:27 UTC
Created attachment 26435 [details]
Message.log
Comment 2 Martin Roskanin 2005-10-31 12:54:23 UTC
probably 3rd-party pmd problem... but I am not sure - reassigning to
openide/text for evaluation
Comment 3 Petr Nejedly 2005-11-29 15:57:49 UTC
Never seen that. Can't reproduce.
The PositionRef$Manager should work pretty well, as it is under heavy load every
day.
Anyway, seems like some race condition there.
Comment 4 Denis Anisimov 2008-03-19 12:57:05 UTC
changeset:   73808:b05ace93c674