Today is the 2nd day of RubyKaigi 2010.
I attended these sessions in this morning:
- If the session has a movie in English, I just write summaries of the article. Please see that movies if you want more details.
- If the session has a movie in Japanese, I write the article with translating and little-summarizing.
- If the session has no movies in any languges, I try to write the article with little-summarizing.
- But, for Ceremonies and Lightning Talks, I only put the link of movies.
- And I don't translate Q&As in the article because these are the gift for attendees in there.
N.B. These summaries may be imprecise.
- Mapping the world with DataMapper
Movie(English)
- by Ted Han
- Goole, Apple, Amazon, Facebook, Last.fm
- These companies aggregate your data instead these companies serve data service for you.
- But you cannot reach all date of these companies in normal way.
- Basic Data Mining : DataMapper will help with these things
- It is able to map to non-relational data, like BigTable.
- Sample : Chorome's URL history
- Chorome's URL history is a simple table of SQLite3 (URL table).
- Describe the colume definitions and validations in the model.
- Use the type from dm-types library.
- The epoc time of Chrome is just Numeric type, not date or time.
- So I define the type ChromeEpocTime for using in DataMapper.
- I make the histogram from this table and its DataMapper.
- Keynote
Title: Ruby 2.0
Movie(Japanese)
- by Matz
- In last week, Ruby 1.9.2 was released
- We(ruby association) give "Ruby 1.9.2 Award" for Yusuke Endoh, as best committer.
- Evolutions of a language
- good enough
- Nearly Perfect
- Perfect
- Ruby is good enough
- Good language
- Good implementation (and other implementations)
- The reason we are here
- But it can be better
- My job is to make ruby nealy perfect
- Things I don't like
- Scope of local variables
- I feel strange that local variable in the block cannot be referred from outside of the block.
- But others feel no strange, so I decide not to change it.
- Mixin defect
- later
- private is not private
- Ruby's private is responding to C++'s protected.
- later
- Monky patch goes global
- Solution: classbox
- Integer division
- "5/2 = 2" is strange while Ruby does not have any types. It should be a"2.5" or rational "5/2".
- Solution: classbox + mathn
- Inheritance
- Inherit attributes from ancestors
- Liscov Substitution Principal
- Important for static typing language(C++, Java)
- Not important for dynamic typing language
- Ruby has "undef". It is incompatible for Liscov Substitution Principal.
- Ruby does not emphasize type and interface consistency.
- Ruby does not have multiple inheritance.
- Mixin
- Substitute of multiple inheritance
- based on Lisp
- Module = Non-primary class (not able to instantiate)
- able to mixin only from Module
- able to mixin many Modules
- Mixin Conflict Problem
- Conflict detection: Is it expected behavior or not expected?
- Conflict resolution: currently, there's only alias.
- Tree modification: inconsistency of Module#ancestors
- There are no around-methods.
- Suggestion for traits(mix function)
mix Module mix Module, Hash mix Module, Array mix Module, Array, Hash- Automatic coflict detection
- Modify method names after mix by Hash
- Define mixable constants by Array
- Ease to find the line error occurs
- Implement the mix is more difficult than implement the include.
- Flaw: leaking private methods when mixed method conflicts with some private method.
- So we can realize real private scope with classbox.
- The first step for Ruby 2.0
- Ruby 2.0
- Starting soon
- I suggest creating branch for 2.0 for other members.
- But other member say to me "You could do in 1.9 trunk"
- Traits
- classbox
- Keyword argument
- other new features
- Sone branch may become the version 2.0, not 1.9.3.
There are many Q&As after Matz' keynote. The most impressive one is Matz' answer when someone ask about specification: "I delegate it for Shugo :-)"
No comments:
Post a Comment