我正在尝试在我的Kotlin项目中使用Java库 .
在库中定义的类型项目中创建变量工作正常,例如 val foo: Foo = fooProvider.get()
,但引入了实际使用这些类型的代码,例如: foo.toString()
,导致编译错误:
Error:Kotlin: Supertypes of the following classes cannot be resolved. Please make sure you have the required dependencies in the classpath:
class com.example.Foo, unresolved supertypes: ajcMightHaveAspect
从我到目前为止发现的我的例子 Foo
类型 implements
ajcMightHaveAspect
这是某种类型的AspectJ接口 .
aspectjrt
在我的类路径上,但我无法在任何地方找到 ajcMightHaveAspect
.
这是Kotlin编译器错误吗?难道我做错了什么?
1 回答
问题已在
AspectJ
中修复 .有关详细信息,请参阅https://bugs.eclipse.org/bugs/show_bug.cgi?id=493554 .
希望它会有所帮助 .