Class: MilkTea::AST::StructDecl

Inherits:
Data
  • Object
show all
Defined in:
lib/milk_tea/core/ast.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name:, type_params:, implements:, c_name:, fields:, events: [], nested_types: [], attributes: [], packed:, alignment:, visibility:, lifetime_params: [], line: nil, column: nil) ⇒ StructDecl

Returns a new instance of StructDecl.



79
# File 'lib/milk_tea/core/ast.rb', line 79

def initialize(name:, type_params:, implements:, c_name:, fields:, events: [], nested_types: [], attributes: [], packed:, alignment:, visibility:, lifetime_params: [], line: nil, column: nil) = super

Instance Attribute Details

#alignmentObject (readonly)

Returns the value of attribute alignment

Returns:

  • (Object)

    the current value of alignment



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def alignment
  @alignment
end

#attributesObject (readonly)

Returns the value of attribute attributes

Returns:

  • (Object)

    the current value of attributes



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def attributes
  @attributes
end

#c_nameObject (readonly)

Returns the value of attribute c_name

Returns:

  • (Object)

    the current value of c_name



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def c_name
  @c_name
end

#columnObject (readonly)

Returns the value of attribute column

Returns:

  • (Object)

    the current value of column



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def column
  @column
end

#eventsObject (readonly)

Returns the value of attribute events

Returns:

  • (Object)

    the current value of events



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def events
  @events
end

#fieldsObject (readonly)

Returns the value of attribute fields

Returns:

  • (Object)

    the current value of fields



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def fields
  @fields
end

#implementsObject (readonly)

Returns the value of attribute implements

Returns:

  • (Object)

    the current value of implements



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def implements
  @implements
end

#lifetime_paramsObject (readonly)

Returns the value of attribute lifetime_params

Returns:

  • (Object)

    the current value of lifetime_params



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def lifetime_params
  @lifetime_params
end

#lineObject (readonly)

Returns the value of attribute line

Returns:

  • (Object)

    the current value of line



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def line
  @line
end

#nameObject (readonly)

Returns the value of attribute name

Returns:

  • (Object)

    the current value of name



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def name
  @name
end

#nested_typesObject (readonly)

Returns the value of attribute nested_types

Returns:

  • (Object)

    the current value of nested_types



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def nested_types
  @nested_types
end

#packedObject (readonly)

Returns the value of attribute packed

Returns:

  • (Object)

    the current value of packed



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def packed
  @packed
end

#type_paramsObject (readonly)

Returns the value of attribute type_params

Returns:

  • (Object)

    the current value of type_params



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def type_params
  @type_params
end

#visibilityObject (readonly)

Returns the value of attribute visibility

Returns:

  • (Object)

    the current value of visibility



78
79
80
# File 'lib/milk_tea/core/ast.rb', line 78

def visibility
  @visibility
end