0

I'm new to Rails and I'm studying Redmine. I see 2 magic function definitions as below:

1.

  def to_s; name end

and 2.

  def <=>(tracker)
    position <=> tracker.position
  end

I cannot understand, please explain what is ";" in "to_s;" and what is "<=>"

Thank you

vietstone
  • 8,344
  • 16
  • 49
  • 73

0 Answers0