[ 
https://issues.apache.org/jira/browse/FLEX-35334?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16075557#comment-16075557
 ] 

Josh Tynjala commented on FLEX-35334:
-------------------------------------

It looks like IDocumentableDefinitionNode defines the getASDocComment() method 
used there, and ITypeNode doesn't have getASDocComment(). I guess that's 
probably why ClassNode was used here, since it implements getASDocComment().

IInterfaceNode and IClassNode extend both ITypeNode and 
IDocumentableDefinitionNode. I think this code can be modified to use 
IDocumentableDefinitionNode to find the @externs tag, and the original 
ITypeNode will allow this code to support both classes and interfaces

> @externs with ActionScript classes works correctly, but incorrect output on 
> an interface
> ----------------------------------------------------------------------------------------
>
>                 Key: FLEX-35334
>                 URL: https://issues.apache.org/jira/browse/FLEX-35334
>             Project: Apache Flex
>          Issue Type: Bug
>          Components: FalconJX
>    Affects Versions: Apache FalconJX 0.8.0
>            Reporter: Josh Tynjala
>
> Compiling the following class with compc will correctly produce 
> externs/ClassExterns.js in the output SWC with a proper @externs tag in the 
> first jsdoc comment:
> {code}
> package
> {
>       /**
>        * @externs
>        */
>       public class ClassExterns
>       {
>               public var variable:String;
>               public function get prop():String {return null};
>               public function set prop(value:String):void {};
>               public function method():Number {return 0};
>       }
> }
> {code}
> However, the following interface produces js/out/InterfaceExterns.js (wrong 
> directory) and the @externs tag is missing in the first jsdoc comment:
> {code}
> package
> {
>       /**
>        * @externs
>        */
>       public interface InterfaceExterns
>       {
>               function get prop():String;
>               function set prop(value:String):void;
>               function method():Number;
>       }
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to