Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
research:software:gradualtalk [2012/07/18 23:39] – [Download] oalvarezresearch:software:gradualtalk [2013/05/09 13:27] eallende
Line 4: Line 4:
  
 The type system of Gradualtalk supports as much Smalltalk idioms as possible through a number of features: a combination of nominal and structural types, union types, self types, parametric polymorphism, and blame tracking, amongst others.  The type system of Gradualtalk supports as much Smalltalk idioms as possible through a number of features: a combination of nominal and structural types, union types, self types, parametric polymorphism, and blame tracking, amongst others. 
 +
 +**Gradualtalk team:** Esteban Allende, Oscar Callaú, Johan Fabry, Éric Tanter
  
 ===== Kind of Types ===== ===== Kind of Types =====
Line 27: Line 29:
 ===== Download ===== ===== Download =====
  
-The latest version of Gradualtalk can be found here:  [[https://ci.lille.inria.fr/pharo/job/Gradual%20Typing/|Gradual Typing (Jenkins)]] +There are two images to download:
- +
-There are two images:+
  
-  * **Types.zip**: The basic image of the Gradual Type System +  * **{{research:software:gradualtalk:gradualtalk.zip|gradualtalk.zip}}**: The basic image of the Gradual Type System 
-  * **Types-KernelTyped.zip**: Has the same functionalities that the basic image, but additionally some kernel classes and the type system has been typed.+  * **{{research:software:gradualtalk:gradualtalk-typedkernel.zip|gradualtalk-typedkernel.zip}}**: Has the same functionalities that the basic image, but additionally some kernel classes and the type system has been typed.
  
 We recommend to use the [[http://www.mirandabanda.org/files/Cog/VM/|Cog VM]]. We recommend to use the [[http://www.mirandabanda.org/files/Cog/VM/|Cog VM]].
Line 143: Line 143:
 Object subclass: #Point Object subclass: #Point
  uses: TTyped  uses: TTyped
-        parametricVariableNames: '(Number)N'+        parametricVariableNames: '<: Number'
  instanceVariableNames: '(N)x (N)y'  instanceVariableNames: '(N)x (N)y'
  classVariableNames: ''  classVariableNames: ''
Line 155: Line 155:
  
 True >> (A) & (A) aBoolean True >> (A) & (A) aBoolean
- <whereType: '(Boolean)A'>+ <whereType: '<: Boolean'>
  ^aBoolean  ^aBoolean
 </code> </code>
Line 178: Line 178:
 By default, method instrumentation and runtime casts are enable. However in some cases, programmers do not want to worry about method instrumentation and runtime casts, eg. type annotations are only a checked documentation of the project. Because of this, we include the ability to disable runtime casts: By default, method instrumentation and runtime casts are enable. However in some cases, programmers do not want to worry about method instrumentation and runtime casts, eg. type annotations are only a checked documentation of the project. Because of this, we include the ability to disable runtime casts:
 <code smalltalk> <code smalltalk>
-TypeConfiguration uniqueInstance enableInstrumentation: false. +Gradualtalk configuration enableInstrumentation: false. 
-TypeConfiguration uniqueInstance enableCasts: false.+Gradualtalk configuration enableCasts: false.
 </code> </code>
  
Line 203: Line 203:
  
 Filein of new code have problems when typechecking, because another method could not exist yet when is being imported. To solve that problem,  the user should: Filein of new code have problems when typechecking, because another method could not exist yet when is being imported. To solve that problem,  the user should:
-  - Disable the type system <code smalltalk>TypeConfiguration uniqueInstance disable: true</code>+  - Disable the type system <code smalltalk>Gradualtalk configuration disable: true</code>
   - Import the code using filein   - Import the code using filein
-  - Enable the type system <code smalltalk>TypeConfiguration uniqueInstance disable: false</code>+  - Enable the type system <code smalltalk>Gradualtalk configuration disable: false</code>
   - Import again the code using file in. A second "file in" is needed in order to properly load the types of instance variables.   - Import again the code using file in. A second "file in" is needed in order to properly load the types of instance variables.