Class: Ast::Merge::AmbiguityMatchingReport

Inherits:
Struct
  • Object
show all
Defined in:
lib/ast/merge.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#ambiguitiesObject

Returns the value of attribute ambiguities

Returns:

  • (Object)

    the current value of ambiguities



661
662
663
# File 'lib/ast/merge.rb', line 661

def ambiguities
  @ambiguities
end

#ambiguousObject

Returns the value of attribute ambiguous

Returns:

  • (Object)

    the current value of ambiguous



661
662
663
# File 'lib/ast/merge.rb', line 661

def ambiguous
  @ambiguous
end

#diagnosticsObject

Returns the value of attribute diagnostics

Returns:

  • (Object)

    the current value of diagnostics



661
662
663
# File 'lib/ast/merge.rb', line 661

def diagnostics
  @diagnostics
end

#matchesObject

Returns the value of attribute matches

Returns:

  • (Object)

    the current value of matches



661
662
663
# File 'lib/ast/merge.rb', line 661

def matches
  @matches
end

#matching_idObject

Returns the value of attribute matching_id

Returns:

  • (Object)

    the current value of matching_id



661
662
663
# File 'lib/ast/merge.rb', line 661

def matching_id
  @matching_id
end

#scope_pathObject

Returns the value of attribute scope_path

Returns:

  • (Object)

    the current value of scope_path



661
662
663
# File 'lib/ast/merge.rb', line 661

def scope_path
  @scope_path
end

#strategyObject

Returns the value of attribute strategy

Returns:

  • (Object)

    the current value of strategy



661
662
663
# File 'lib/ast/merge.rb', line 661

def strategy
  @strategy
end

Instance Method Details

#to_hObject



663
664
665
666
667
668
669
670
671
672
673
# File 'lib/ast/merge.rb', line 663

def to_h
  {
    matching_id: matching_id,
    strategy: strategy,
    scope_path: scope_path,
    ambiguous: ambiguous,
    matches: (matches || []).map(&:to_h),
    ambiguities: (ambiguities || []).map(&:to_h),
    diagnostics: diagnostics || []
  }
end