mirror of
https://github.com/cincheo/jsweet.git
synced 2025-12-15 15:29:22 +00:00
fixed error on Ambient interfaces complaining about method body while in
interface
This commit is contained in:
parent
58d0d3ba2f
commit
7d904fae98
@ -717,7 +717,7 @@ public class Java2TypeScriptTranslator extends AbstractTreePrinter {
|
||||
report(methodDecl, methodDecl.name, JSweetProblem.NATIVE_MODIFIER_IS_NOT_ALLOWED, methodDecl.name);
|
||||
}
|
||||
} else {
|
||||
if (declareClassScope && !constructor) {
|
||||
if (declareClassScope && !constructor && !interfaceScope) {
|
||||
report(methodDecl, methodDecl.name, JSweetProblem.INVALID_METHOD_BODY_IN_INTERFACE, methodDecl.name, parent.name);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user