Syntax::ClassDef
Inherits Syntax::ASTNode < Reference < Object
Class definition:
'class' name [ '<' superclass ]
body
'end'
Constructors
new(name : Syntax::Path, body = nil, superclass : Syntax::ASTNode | Nil = nil, type_vars : Nil | Array(String) = nil, abstract __arg39 : Bool = false, struct __arg40 : Bool = false, splat_index : Int32 | Nil = nil)
SourceInstance methods
==(other : self)
Returns true if this reference is the same as other. Invokes same?.
abstract?
Sourceaccept_children(visitor)
Sourcebody
Sourcebody=(body : ASTNode)
Sourceclone_without_location
Sourcedoc
Returns the doc comment attached to this node. Not every node
supports having doc comments, so by default this returns nil.
hash(hasher)
See Object#hash(hasher)
name
Sourcename_location
Sourcename_location=(name_location : Location | Nil)
Sourcesplat_index
Sourcestruct?
Sourcesuperclass
Sourcesuperclass=(superclass : ASTNode | Nil)
Sourcetype_vars
Sourcevisibility
Sourcevisibility=(visibility : Syntax::Visibility)
Source