Class: MilkTea::SemanticAnalyzer::ModuleContext
- Inherits:
-
Object
- Object
- MilkTea::SemanticAnalyzer::ModuleContext
- Defined in:
- lib/milk_tea/core/semantic_analyzer/module_context.rb
Instance Attribute Summary collapse
-
#ast ⇒ Object
Returns the value of attribute ast.
-
#attribute_application_bindings ⇒ Object
Returns the value of attribute attribute_application_bindings.
-
#attributes ⇒ Object
Returns the value of attribute attributes.
-
#const_declarations ⇒ Object
Returns the value of attribute const_declarations.
-
#global_import_index ⇒ Object
Returns the value of attribute global_import_index.
-
#implemented_interfaces ⇒ Object
Returns the value of attribute implemented_interfaces.
-
#imported_modules ⇒ Object
Returns the value of attribute imported_modules.
-
#imports ⇒ Object
Returns the value of attribute imports.
-
#interfaces ⇒ Object
Returns the value of attribute interfaces.
-
#methods ⇒ Object
Returns the value of attribute methods.
-
#module_kind ⇒ Object
Returns the value of attribute module_kind.
-
#module_name ⇒ Object
Returns the value of attribute module_name.
-
#resolved_attribute_applications ⇒ Object
Returns the value of attribute resolved_attribute_applications.
-
#top_level_functions ⇒ Object
Returns the value of attribute top_level_functions.
-
#top_level_values ⇒ Object
Returns the value of attribute top_level_values.
-
#types ⇒ Object
Returns the value of attribute types.
-
#validated_attribute_arguments ⇒ Object
Returns the value of attribute validated_attribute_arguments.
Instance Method Summary collapse
-
#initialize(ast:, module_name:, module_kind:, imported_modules:, global_import_index:, const_declarations:) ⇒ ModuleContext
constructor
A new instance of ModuleContext.
Constructor Details
#initialize(ast:, module_name:, module_kind:, imported_modules:, global_import_index:, const_declarations:) ⇒ ModuleContext
Returns a new instance of ModuleContext.
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 14 def initialize(ast:, module_name:, module_kind:, imported_modules:, global_import_index:, const_declarations:) @ast = ast @module_name = module_name @module_kind = module_kind @imported_modules = imported_modules @global_import_index = global_import_index @const_declarations = const_declarations @types = {} @interfaces = {} @attributes = {} @top_level_values = {} @top_level_functions = {} @imports = {} @methods = Hash.new { |hash, key| hash[key] = {} } @implemented_interfaces = Hash.new { |hash, key| hash[key] = [] } @resolved_attribute_applications = {} @validated_attribute_arguments = {} @attribute_application_bindings = {} end |
Instance Attribute Details
#ast ⇒ Object
Returns the value of attribute ast.
6 7 8 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 6 def ast @ast end |
#attribute_application_bindings ⇒ Object
Returns the value of attribute attribute_application_bindings.
12 13 14 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 12 def attribute_application_bindings @attribute_application_bindings end |
#attributes ⇒ Object
Returns the value of attribute attributes.
9 10 11 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 9 def attributes @attributes end |
#const_declarations ⇒ Object
Returns the value of attribute const_declarations.
8 9 10 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 8 def const_declarations @const_declarations end |
#global_import_index ⇒ Object
Returns the value of attribute global_import_index.
7 8 9 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 7 def global_import_index @global_import_index end |
#implemented_interfaces ⇒ Object
Returns the value of attribute implemented_interfaces.
11 12 13 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 11 def implemented_interfaces @implemented_interfaces end |
#imported_modules ⇒ Object
Returns the value of attribute imported_modules.
7 8 9 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 7 def imported_modules @imported_modules end |
#imports ⇒ Object
Returns the value of attribute imports.
11 12 13 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 11 def imports @imports end |
#interfaces ⇒ Object
Returns the value of attribute interfaces.
9 10 11 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 9 def interfaces @interfaces end |
#methods ⇒ Object
Returns the value of attribute methods.
11 12 13 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 11 def methods @methods end |
#module_kind ⇒ Object
Returns the value of attribute module_kind.
6 7 8 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 6 def module_kind @module_kind end |
#module_name ⇒ Object
Returns the value of attribute module_name.
6 7 8 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 6 def module_name @module_name end |
#resolved_attribute_applications ⇒ Object
Returns the value of attribute resolved_attribute_applications.
12 13 14 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 12 def resolved_attribute_applications @resolved_attribute_applications end |
#top_level_functions ⇒ Object
Returns the value of attribute top_level_functions.
10 11 12 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 10 def top_level_functions @top_level_functions end |
#top_level_values ⇒ Object
Returns the value of attribute top_level_values.
10 11 12 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 10 def top_level_values @top_level_values end |
#types ⇒ Object
Returns the value of attribute types.
9 10 11 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 9 def types @types end |
#validated_attribute_arguments ⇒ Object
Returns the value of attribute validated_attribute_arguments.
12 13 14 |
# File 'lib/milk_tea/core/semantic_analyzer/module_context.rb', line 12 def validated_attribute_arguments @validated_attribute_arguments end |