jsweet icon indicating copy to clipboard operation
jsweet copied to clipboard

Can't Extend from Parallel Directory Structure

Open bcwhite-code opened this issue 1 year ago • 0 comments

Using the latest JSweet...

I have a class defined in java/com/foo/lib/Thing.java:

package com.foo.lib;
public class com.foo.lib.Thing {
  ... some methods ...
}

It transpiles just fine.

I have another class in java/com/foo/project/common/MyThing.java:

package com.foo.project.common;
public class MyThing extends com.foo.lib.Thing {
  ... methods making calls to methods from Thing ...
}

This works fine compiled with Java but It fails to transpile with JSweet, saying:

cannot find name 'Thing' at (every line that calls a method inside Thing)

If I move "Thing" to be in java/com/foo/project/common or even java/com/foo/project then it'll transpile just fine even if I don't change the path.to.Thing after "extends".

It seems like JSweet only looks up the directory structure for classes to extend and not the defined path.

bcwhite-code avatar Jan 23 '23 01:01 bcwhite-code