© Oscar Nierstrasz ST — Introduction ST 1.1 A Word about Primitives  For optimization, if a primitive fails, the code following is executed. 

Slides:



Advertisements
Similar presentations
The "if structure" is used to execute statement(s) only if the given condition is satisfied.
Advertisements

Dynamic Object-Oriented Programming with Smalltalk 1. Introduction Prof. O. Nierstrasz.
Carnegie Mellon Lecture 7 Instruction Scheduling I. Basic Block Scheduling II.Global Scheduling (for Non-Numeric Code) Reading: Chapter 10.3 – 10.4 M.
Portability and Safety Mahdi Milani Fard Dec, 2006 Java.
1 Starting a Program The 4 stages that take a C++ program (or any high-level programming language) and execute it in internal memory are: Compiler - C++
The Fundamental Rule for Testing Methods Every method should be tested in a program in which every other method in the testing program has already been.
9. Bytecode and Virtual Machines Original material prepared by Adrian Lienhard and Marcus Denker.
2. Smalltalk Basics. © Oscar Nierstrasz ST — Smalltalk Basics 2.2 Roadmap  Everything is an Object  Syntax on a Postcard  Three Kinds of Messages 
Stéphane Ducasse«ChapterNr».1 Abstract Classes Should not be instantiated (abstract in Java) But can defined complete methods Defines a protocol common.
Stéphane Ducasse8.1 Syntax and Messages The syntax of Smalltalk is simple and uniform, but it can look strange at first sight! Literals: numbers, strings,
© Oscar Nierstrasz ST — Smalltalk Basics 2.1 Change sets  Make sure your changes are logged to a new change set.
13. A bit of Smalltalk. © Oscar Nierstrasz 2 Roadmap  The origins of Smalltalk  What is Smalltalk?  Syntax in a nutshell  Seaside — web development.
Dynamic Object-Oriented Programming with Smalltalk 1. Introduction Prof. O. Nierstrasz Summer Semester 2006.
2. Smalltalk Basics. © Oscar Nierstrasz ST — Smalltalk Basics 2.2 Roadmap  Everything is an Object  Syntax on a Postcard  Three Kinds of Messages 
© Oscar Nierstrasz ST — Smalltalk Basics 2.1 Change sets  Make sure your changes are logged to a new change set.
Evan Korth New York University Computer Science I Classes and Objects Professor: Evan Korth New York University.
© Oscar Nierstrasz ST — Introduction ST 1.1 Scaffolding Patterns  How to prototype applications even faster?  Based on K. Auer Patterns.
True/False. False True Subject May Go Here True / False ? Type correct answer here. Type incorrect answer here.
Stéphane Ducasse 1 Objects to the Roots: Learning from beauty.
Determine whether each curve below is the graph of a function of x. Select all answers that are graphs of functions of x:
Stéphane Ducasse5.1 Smalltalk in a Nutshell OO Model in a Nutshell Syntax in a Nutshell.
Stéphane Ducasse 1 Smalltalk in a Nutshell.
Slide 1 Chapter 10 Class and Method Design. Slide 2 REVISITING THE BASIC CHARACTERISTICS OF OBJECT-ORIENTATION.
Peter Juszczyk CS 492/493 - ISGS. // Is this C# or Java? class TestApp { static void Main() { int counter = 0; counter++; } } The answer is C# - In C#
Computer Science 209 The Strategy Pattern II: Emulating Higher-Order Functions.
3A-1 1 Introduction to Smalltalk History of Smalltalk The philosophy of Smalltalk:  “...we have a universe of well-behaved objects that courteously ask.
3E-1 Collections in Squeak What are they? Kinds of collections. Basic Operations. Usage of Inheritance in the Collections Library. Roman numbers example.
A brief introduction to 11ACM 朱旻申. Outline What is Groovy ? Differences between Groovy & Java About closure & Dagger Methods.
Effective C#, Chapter 1: C# Language Elements Last Updated: Fall 2011.
CS 403: Programming Languages Lecture 6 Fall 2003 Department of Computer Science University of Alabama Joel Jones.
Object-oriented Programming and Design 1 Polymorphism Poly => many Morph => shape Variables take on many shapes, or many classes of objects.
Smalltalk (and Squeak) Aida Dungan and Rick Shreve.
Review: 6.5f Mini-Quiz 1. Solve: Verify by factoring. 2. Solve by Graphing: y = x 2 – 4x. Verify by factoring.
CS 598 Scripting Languages Design and Implementation 14. Self Compilers.
3C-1 Identifiers Variables Literal Objects  Numbers  Characters  Strings Control Structure  Blocks  Conditionals  Loops Messages Defining New Classes.
Smalltalk Interpreted by Alan Frazier & Brian Sparks.
1 Advanced Object Oriented Systems (CM0318) Lecture 8 (Last updated 15th February 2002)
S.Ducasse Stéphane Ducasse 1 Smalltalk in a Nutshell.
Stéphane Ducasse 1 Abstract Classes.
Google C++ Testing Framework Part 2: Assertion. Concepts A test case contains one or many tests. ◦ You should group your tests into test cases that reflect.
Title Category #1 Category #2 Category #3Category #
A Survey of Object-Oriented Concepts, by Oscar Nierstrasz Reviewed by Odd Petter N. Slyngstad for DT8100, 27/1/2005.
IELTS Reading Test Introduction True or False?. The test lasts 60 minutes. – True.
Operational Semantics of Scheme
Environments and the Contour Model
Sections Basic Concepts of Programming
Road Map Introduction to object oriented programming. Classes
Factors, multiple, primes: Factors from prime factors
Tackling Software Navigation Issues of the Smalltalk IDE
Aaron Bloomfield CS 415 Fall 2005
Introduction to Testing, SUnit and Error Handling
Algorithm Discovery and Design
Lecture 25: Metalinguistics > (meval '((lambda (x) (* x x)) 4)
Choose the best answer for each problem.
True or False: {image} is one-to-one function.
Copyright 2000, Georgia Tech
Programming Languages
CSE 3302 Programming Languages
Assignment #3 Programming Language, Spring 2003
Let’s Talk about… Smalltalk.
Among the Hidden/Fahrenheit 451
Social Practice of the language: Describe and share information
Type Topic in here! Created by Educational Technology Network
Inequalities TRUE FALSE.
Factors, multiple, primes: Multiples
If there is any case in which true premises lead to a false conclusion, the argument is invalid. Therefore this argument is INVALID.
Standard form: In standard form?
True or False True or False
If there is any case in which true premises lead to a false conclusion, the argument is invalid. Therefore this argument is INVALID.
Presentation transcript:

© Oscar Nierstrasz ST — Introduction ST 1.1 A Word about Primitives  For optimization, if a primitive fails, the code following is executed.  y —"Answer a new Point whose x value is the receiver —and whose y value is the argument."  — —^Point x: self y: y

© Oscar Nierstrasz ST — Introduction ST 1.2 At the End of the Smalltalk World  We need some operations that are not defined as  methods on objects but direct calls on the underlying  implementation language (C, Assembler,...)  == anObject  "Answer true if the receiver and the argument are the same object (have the same object pointer) and false otherwise. Do not redefine the message == in any other class! No Lookup." — —self primitiveFailed  + - * / = == bitShift:\\ bitAnd: bitOr: >= <= at: at:put: new new:

© Oscar Nierstrasz ST — Introduction ST 1.3 Encapsulation

© Oscar Nierstrasz ST — Introduction ST 1.4 Squeak Map Package Loader