This page is no longer maintained — Please continue to the home page at www.scala-lang.org

"illegal cyclic reference" when compiling file

No replies
Moritz Uhlig
Joined: 2010-01-08,
User offline. Last seen 42 years 45 weeks ago.

Hello all,

I'm currently writing a NetBeans Platform application in Scala 2.8 and experienced a strange bug when using the DataLoader/DataObject classes.

I could reduce the code to reproduce the problem to the following:

//---8<---

package scalabug

import org.openide.filesystems._
import org.openide.loaders._

// abstract class Dummy extends DataObject(null, null)

class SomeDataObject(primaryFile : FileObject, loader : MultiFileLoader) extends MultiDataObject(primaryFile, loader)

//--->8---

When compiling the file I get an error message "scalabug.scala:8: error: illegal cyclic reference involving object DataLoader".

If I now uncomment the line containing the Dummy class, the compilations succeeds. I already searched the bug tracker but could not find any related bug.

Is this a known bug or is there maybe some kind of irregularity in the referenced NetBeans libraries? I tried this with different Scala nightlies starting from r19264 up to r20397 and the latest Beta1-RCs as well as with different NetBeans 6.8 snapshots and the 6.8 release but the problem persists.

Regards,

Moritz

Copyright © 2012 École Polytechnique Fédérale de Lausanne (EPFL), Lausanne, Switzerland