@@ -822,7 +822,9 @@ class ModuleNode instanceof Module {
822
822
*
823
823
* Does not take inheritance into account.
824
824
*/
825
- MethodNode getAnOwnSingletonMethod ( ) { result .asMethod ( ) = super .getAnOwnSingletonMethod ( ) }
825
+ MethodNode getAnOwnSingletonMethod ( ) {
826
+ result .asCallableAstNode ( ) = super .getAnOwnSingletonMethod ( )
827
+ }
826
828
827
829
/**
828
830
* Gets the singleton method named `name` declared in this module (or in a singleton class
@@ -841,7 +843,7 @@ class ModuleNode instanceof Module {
841
843
* Does not take inheritance into account.
842
844
*/
843
845
MethodNode getAnOwnInstanceMethod ( ) {
844
- result .asMethod ( ) = this .getADeclaration ( ) .getAMethod ( ) .( Method )
846
+ result .asCallableAstNode ( ) = this .getADeclaration ( ) .getAMethod ( ) .( Method )
845
847
}
846
848
847
849
/**
@@ -860,7 +862,7 @@ class ModuleNode instanceof Module {
860
862
* Does not take inheritance into account.
861
863
*/
862
864
ParameterNode getAnOwnInstanceSelf ( ) {
863
- result = TSelfParameterNode ( this .getAnOwnInstanceMethod ( ) .asMethod ( ) )
865
+ result = TSelfParameterNode ( this .getAnOwnInstanceMethod ( ) .asCallableAstNode ( ) )
864
866
}
865
867
866
868
/**
@@ -1015,10 +1017,10 @@ class MethodNode extends CallableNode {
1015
1017
MethodNode ( ) { super .asCallableAstNode ( ) instanceof MethodBase }
1016
1018
1017
1019
/** Gets the underlying AST node for this method. */
1018
- MethodBase asMethod ( ) { result = this .asCallableAstNode ( ) }
1020
+ override MethodBase asCallableAstNode ( ) { result = super .asCallableAstNode ( ) }
1019
1021
1020
1022
/** Gets the name of this method. */
1021
- string getMethodName ( ) { result = this .asMethod ( ) .getName ( ) }
1023
+ string getMethodName ( ) { result = this .asCallableAstNode ( ) .getName ( ) }
1022
1024
}
1023
1025
1024
1026
/**
@@ -1028,7 +1030,7 @@ class BlockNode extends CallableNode {
1028
1030
BlockNode ( ) { super .asCallableAstNode ( ) instanceof Block }
1029
1031
1030
1032
/** Gets the underlying AST node for this block. */
1031
- Block asBlock ( ) { result = this .asCallableAstNode ( ) }
1033
+ override Block asCallableAstNode ( ) { result = super .asCallableAstNode ( ) }
1032
1034
}
1033
1035
1034
1036
/**
0 commit comments