From: drew@... (Andrew D. McDowell) Date: 2000-11-30T15:10:05+09:00 Subject: [ruby-talk:6666] Suggestion for addition to Begin/End syntax Hi all. I'm very new to Ruby so this might be a bit of a shot in the dark, but I'd like to suggest a minor change in the block 'end' syntax that may help readability. It's not a new idea, but it's something that I found helpfull when reading Dylan code: When the 'end' statement is used to close a code block, allow an optional word or two of description. They can be ignored by the interpreter, but it'd be usefull for debugging for them to be matched. Basicaly, any of the following would be acceptable: def foo() print "Foo!\n" end -or- def foo() print "Foo!\n" end def -or- def foo() print "Foo!\n" end foo -or- def foo() print "Foo!\n" end def foo --- An example class (from samples/list.rb) could become: class MyList def add_to_list(obj) elt = MyElem.new(obj) if @head @tail.succ = elt else @head = elt end if @tail = elt end add_to_list def each elt = @head while elt yield elt elt = elt.succ end while end each def to_s str = "