Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Modified description for alias #2

Closed
wants to merge 1 commit into from

2 participants

@kalmanh

David,

The sample code for the alias keyword was incorrect. (see issue #1)

I fixed that and added a few more lines to clarify exactly what's happening.

Thanx,

-Kalman Hazins

@dblack
Owner
@kalmanh

Great!

Thanx,

-Kalman

@kalmanh kalmanh closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Dec 30, 2011
  1. @kalmanh

    Modified description for alias

    kalmanh authored
This page is out of date. Refresh to see the latest.
Showing with 7 additions and 2 deletions.
  1. +7 −2 keywords.rb
View
9 keywords.rb
@@ -108,7 +108,10 @@ def END
# end
#
# p = Person.new
- # p.name = "David" # Naming your person David!
+ # p.full_name = "David" # => Naming your person David!
+ #
+ # # Can still use name=
+ # p.name = "Jack" # => Naming your person Jack!
#
# class Person
# def name=(name)
@@ -116,7 +119,9 @@ def END
# end
# end
#
- # p.full_name = "David" # Please use fullname=
+ # # Even though name= got overriden - fullname= still works
+ # p.full_name = "David" # => Naming your person David!
+ # p.name = "David" # => Please use fullname=
def alias
end
Something went wrong with that request. Please try again.