Upgrade to Pro — share decks privately, control downloads, hide ads and more …

A Small Smalltalk Talk [RUG::B edition]

A Small Smalltalk Talk [RUG::B edition]

Denis Defreyne

July 02, 2015
Tweet

More Decks by Denis Defreyne

Other Decks in Technology

Transcript

  1. A Small
    talk
    SMALLTALK
    Denis Defreyne / @ddfreyne / [email protected]

    View full-size slide

  2. Bad news:
    Smalltalk is dead.
    SMALLTALK

    View full-size slide

  3. Three reasons to
    look into SMALLTALK

    View full-size slide

  4. 1.
    Smalltalk is is worth learning
    because of its heritage.
    SMALLTALK

    View full-size slide

  5. 2.
    Smalltalk is is worth learning
    because it is weird.
    SMALLTALK

    View full-size slide

  6. 3.
    Smalltalk is is worth learning
    because it encourages exploration.
    SMALLTALK

    View full-size slide

  7. is like Ruby
    SMALLTALK RUBY

    View full-size slide

  8. is like Ruby
    RUBY SMALLTALK

    View full-size slide

  9. Smalltalk ’s model of object orientation
    is identical to ’s
    RUBY
    SMALLTALK

    View full-size slide

  10. 'Hello'.upcase
    'Hello' asUppercase.
    RUBY
    SMALLTALK

    View full-size slide

  11. person = Person.new
    person.first_name = 'Denis'

    person := Person new.
    person firstName: 'Denis'.
    SMALLTALK
    RUBY

    View full-size slide

  12. research_paper.respond_to?(:complete?)
    research_paper.send(:add_random_paragraph)

    researchPaper respondsTo: #isComplete.
    researchPaper perform: #addRandomParagraph.
    SMALLTALK
    RUBY

    View full-size slide

  13. people.each { |person| self.send_spam_to(person) }
    people do: [ :person | self sendSpamTo: person ].
    people do: [ :each | self sendSpamTo: each ].
    RUBY
    SMALLTALK

    View full-size slide

  14. people.each { |person| self.send_spam_to(person) }
    people do: [ :person | self sendSpamTo: person ].
    people do: [ :each | self sendSpamTo: each ].
    RUBY
    SMALLTALK

    View full-size slide

  15. people.select { |person| person.adult? }
    people.select(&:adult?)

    people select: [ :person | person isAdult ].
    people select: #isAdult.
    RUBY
    SMALLTALK

    View full-size slide

  16. people select: #isAdult.
    people detect: #isAdult.
    people reject: #isAdult.
    people collect: #firstName.
    people inject: 0 into: [ :memo :each | memo + each age ]
    SMALLTALK

    View full-size slide

  17. is a cleaner
    SMALLTALK RUBY

    View full-size slide

  18. poke = lambda { |person| person.poke }
    people.each(&poke)

    poke := [ :person | person poke ].
    people do: poke.
    RUBY
    SMALLTALK

    View full-size slide

  19. if students.empty?
    cancel_class
    end

    students isEmpty ifTrue:
    [self cancelClass].
    RUBY
    SMALLTALK

    View full-size slide

  20. as inspiration
    SMALLTALK

    View full-size slide

  21. (at all)
    is not like
    SMALLTALK RUBY

    View full-size slide

  22. Smalltalk
    SMALLTALK

    View full-size slide

  23. Smalltalk
    SMALLTALK

    View full-size slide

  24. Smalltalk
    SMALLTALK
    =

    View full-size slide

  25. Smalltalk
    SMALLTALK
    – your application
    =

    View full-size slide

  26. Smalltalk
    SMALLTALK
    – your application
    – standard library
    =

    View full-size slide

  27. Smalltalk
    SMALLTALK
    – your application
    – standard library
    – other libraries
    =

    View full-size slide

  28. Smalltalk
    SMALLTALK
    – your application
    – standard library
    – other libraries
    – compiler
    =

    View full-size slide

  29. Smalltalk
    SMALLTALK
    – your application
    – standard library
    – other libraries
    – compiler
    – IDE
    =

    View full-size slide

  30. Smalltalk
    SMALLTALK
    Pharo.image

    View full-size slide

  31. Smalltalk
    SMALLTALK
    Pharo.image
    FRESH

    View full-size slide

  32. Smalltalk
    SMALLTALK
    COPY
    Pharo.image
    FRESH

    View full-size slide

  33. ✓ Heritage

    View full-size slide

  34. ✓ Heritage
    ✓ Weirdness

    View full-size slide

  35. ✓ Heritage
    ✓ Weirdness
    ✓ Exploration

    View full-size slide

  36. Why is wh dead?
    SMALLTALK

    View full-size slide

  37. 1. The Smalltalk environment is isolated.

    View full-size slide

  38. 1. The Smalltalk environment is
    2. The Smalltalk community suffers from NIH.

    View full-size slide

  39. 1. The Smalltalk environment is
    2. The Smalltalk community suffers from
    3. Smalltalk isn’t revolutionary anymore.

    View full-size slide

  40. @ddfreyne
    [email protected]
    Denis Defreyne
    Former Smalltalk developer
    DENIS DEFREYNE

    View full-size slide