Language & Compiler =================== Differences in the Clean Language and the Clean compiler version 1.2.4 -> version 1.3 Release 1.3.1 (January 1999) ============================ PowerMac - CleanIDE: printing added - Profiling tools: printing added Windows - IOInterface 0.8: fixed bug for Asian systems - CleanIDE: printing added : fixed bug for Asian systems : fixed copy bug, CleanIDE no longer converts clipboard to plain text when something is copied from another application - Profiling tool: printing added Release 1.3 (April 1998) ======================== - The compiler can now read files with all new line conventions (Mac, Dos, Unix). - In a record and array update one can directly update any substructure. - There is a special selector for unique records and arrays which returns the selected element as well as the unique record / array such that the record / array can be easily updated with a value depending on the selected element. - The compiler and code generator optionally take user defined uniqueness type information into account to perform compile-time garbage collection for unique data structures in simple cases. - A time profiler (PowerMac and Windows) and space profiler (PowerMac) has been added. - It is no longer required to import all constructors of an algebraic type, when the type is imported explicitly. - { and } are no longer treated in a special way by the lay-out rule. StdEnv ====== Differences in the Clean Standard Environment (StdEnv) version 1.2.4 -> version 1.3 StdEnv ------ StdOrdList new module (operations on list for which there is an ordening on the elements) StdChar ------- toInt (Char) moved to StdInt toString (Char) moved to StdString toChar (Int) moved from StdInt digToInt renamed digitToInt isOctDigit new isHexDigit new StdFile ------- FileSystem new class with file access functions (fopen, fclose, sfopen, stdio) with instances for Files and World FileEnv new class with Files access functions (accFiles and appFiles) with an instance for world openfiles removed closefiles removed freadline changed to return a unique string can now also be used on data files, in which case it will recognise all new line conventions (Mac, Dos, Unix). (<<<) new class: write to file with instances for Int, Char, {#Char} and Real StdFunc ------- I renamed id K renamed const S removed (o) changed to a macro `bind` changed to a macro return changed to a macro StdInt ------ isEven, isOdd, (mod), (rem), gcd, lcm changed to instance of overloaded function toInt (Char) moved from StdChar toInt ({#Char} moved from StdString toChar (Int) moved to StdChar toReal (Int) moved to StdReal toString (Int) moved to StdString StdList ------- init new remove renamed removeAt insertAt new updateAt new maxList, minList, sort, merge moved to StdOrdList isAnyMember new removeMember new removeIndex new StdOverloaded ------------- isEven, isOdd, (mod), (rem), gcd, lcm new overloaded functions ln, log10, exp, sqrt, sin, cos, tan, asin, acos, atan, sinh, cosh, tanh, asinh, acosh, atanh new overloaded functions StdReal ------- toInt (Real) moved to StdInt toString (Real) moved to StdString toReal (Int) moved from StdInt toReal ({#Char}) moved from StdString ln, log10, exp, sqrt, sin, cos, tan, asin, acos, atan, sinh, cosh, tanh, asinh, acosh, atanh changed to instance of overloaded function StdString --------- (+++.) new toString (Int) moved from StdInt toString (Char) moved from StdChar toString (Real) moved from StdReal toInt ({#Char}) moved to StdInt toReal ({#Char}) moved to StdReal IOlib 0.8 ========= Differences between previous release of Clean, version 1.2.4 and the new release, version 1.3d9. * IO Examples 0.8 * IOUtitilities * Help.dcl: - Type of MakeAboutDialog and ShowHelp have changed because of new StdFile access. * Help.icl: - Implementation of MakeAboutDialog and ShowHelp have changed because of new StdFile access. * Highscore.dcl: - The type HiScores does not contain a Files environment anymore. Therefore it is no longer necessary to propagate the uniqueness attribute *. - The type Highs has becomes obsolete (identical to HiScores). - The type High has been renamed to HiScore. - The function type definitions have a *File argument and result instead of File. Their types are also changed according to the changes above. * Highscore.icl: - Implementation of functions changed because of changes described above. * Random.icl: - Only syntactic changes. * Life * Life.icl: - Only syntactic changes. * LifeGameExample.icl: - Help information has been added using the Help module from IOUtilities. This changes the Start rule: the AboutDialog must be created and added to the initial IOSystem. - Applications of DrawInActiveWindow have been replaced by DrawInWindow WindowID. This is necessary because otherwise cells can be drawn in the Help window. - Syntactic changes. * Mandelbrot * Complex.dcl: - ComplexNum has become a record rather than a tuple. - The functions AddC, SubC, MulC have become overloaded instances of +, -, *. An instance for zero has also been introduced. - SinC, CosC, ExpC, FakeAbsC have been renamed to sinC, cosC, expC, sqdist. * Complex.icl: - Implementations have changed according to changes described above. - Syntactic changes. * FractalDemo.icl: - Help information has been added using the Help module from IOUtilities. This changes the Start rule: the AboutDialog must be created and added to the initial IOSystem. - The titles of the CheckMenuItems of the SubMenuItem "Predefined Areas" now start with a capital. - The SubMenuItem "Mandelbrot Functions" has been eliminated. The function that is used is always the 'standard' Mandelbrot function. Therefore, also the fun field of the FunctionState record is obsolete; this causes some small changes in the code. - The functions DefFunction and DefaultFunction have become obsolete. - Syntactic changes. * FractalTypes.dcl: - The record field fun of FunctionState has been eliminated (explained above). - The type FractalFunction has been eliminated (explained above). - The function SetFFunction has become obsolete. - Syntactic changes. * FractalTypes.icl: - Implementations have changed according to changes described above. - Synctactic changes. * Mandelbrot.icl: - The function Fractal_color changes because the 'standard' Mandelbrot is used. - The function MandelSquare gets a new definition because of overloaded Complex numbers. - Syntactic changes. * Mines * Mines.icl: - Help information has been changed because the Help module has changed. This changes the Start rule. Other changes due to StdFile differences. - The type MinesBest has become obsolete (see module MineTypes about changes). These influence applications of MinesBest (the functions Help, UpdateBest, CheckForBestTime, Ok). - Syntactic changes. * MinesBest.dcl: - Because of changes of type definition of MinesBest (into BestTimes) the type definitions of ReadHiScores and WriteHiScores change. * MinesBest.icl: - Implementations have changed according to changes described above. - Local function definitions ReadHighs and ReadThreeTimes have been placed in where clause to improve readibility. - Further syntactic changes. * MinesHelp: - Text has changed. * MineTypes.dcl: - The type MinesBest has been eliminated. * MineTypes.icl: - Implementations have changed according to changes described above. - Syntactic changes. * Scrabble * board.icl: - Syntactic changes only. * graphics.icl: - Module StdOrdList added in import list. - Syntactic changes only. * language.(d/i)cl: - Module types imported rather than board. * scrabble.icl: - Start rule changes because of different Files and Events handling. - The help function has changed because of changes in Help module. - The quit function has changed. QuitIO is always done, so it is moved before decision alternative. Because of different Files access, writing the tree is also different. - Syntactic changes. * state.dcl: - Record field files has been eliminated from the State record. - The initstate function now expects a lexicon tree rather than the Files environment. * state.icl: - Implementations have changed according to changes described above. - Syntactic changes. * types.dcl: - Occurrences of type Files have been replaced by *Files. * types.icl: - Occurrences of type Files have been replaced by *Files. - The function writelines now uses the new operator <<< to write data to file. - The K function has been renamed to const (change of StdFunc). - Syntactic changes. * Simple DataBase * listextensions.(d/i)cl: - The functions insertAt and updateAt have become obsolete because they have been defined in the new StdList. * Module database.icl has been split into main module simpleDB.icl and a module basicDB.(d/i)cl. The new version is more than an adjustment to the new Clean environment. * Small IO Examples * CalcDialog.icl: - Start rule has changed because of different Event handling. - The K function has been renamed to const (module StdFunc). - Syntactic changes. * draw.icl: - Start rule has changed because of different Event handling. - Syntactic changes. * Hanoi.icl: - Start rule has changed because of different Event handling. - Syntactic changes. * HelloWorld.icl: - Start rule has changed because of different Event handling. - Syntactic changes. * Turing * showtm.icl: - Syntactic changes only. * tm.dcl: - Syntactic changes only. * tm.icl: - Syntactic changes only. * tmdialog.dcl: - Import of tmfile has become obsolete. - Record field 'disk' of record Tm has become obsolete. * tmdialog.icl: - Implementations have changed according to changes described above. - Import rules have been made more concise. - SvBfClSave function has changes because of different Files handling. - Syntactic changes. * tmfile.dcl: - The type Disk has become obsolete, and has been replaced by Files. This changes the types of the functions WriteTuringToFile and ReadTuring. * tmfile.icl: - Implementations have changed according to changes described above. - Writing a Turing data structure to file has been changed making use of the overloaded <<< operator. Four new instances of this operator are defined; for Turing, Transition, Tape, and []. - Syntactic changes. * Turing.icl: - Start rule has changed because of different Event handling. - Initial Turing state has become a local definition of the Start rule, rather than a function NewTuring because of different Files handling. - The record field 'disk' has been removed in all applications. - File handling has changed in various functions due to different Files handling (DoSave,DoSaveAs,OpenTuring). - The Help function has changed because of new Help module. - Syntactic changes. * TuringHelp: - Text has changed. * Worm * worm.icl: - Start rule has changed because of different Event and Files handling. - The Help function has changed because of new Help module. - Changes of the State record with respect to the high scores (ShowBest, OverOK). - Syntactic changes. * WormHelp: - Text has changed. * wormshow.icl: - Import rules have changed. - Syntactic changes. * wormstate.icl: - Syntactic changes only. IOInterface 0.8 Of many modules the only difference is the uniqueness attribution of type Toolbox to *Toolbox in type definitions of functions and data types. This occurs in the following modules: commonDef.(d/i)cl, deltaDialog.icl, deltaFileSelect.icl, deltaMenu.icl, deltaTimer.icl, dialogAccess.(d/i)cl, dialogDevice.icl, dialogInternal.(d/i)cl, dialogLayout.(d/i)cl, dialogUpdate.(d/i)cl, event.(d/i)cl, menuDevice.icl, menuInternal.(d/i)cl, Picture.(d/i)cl, timerDevice.(d/i)cl, Window1.icl, Window2.icl, windowAccess.(d/i)cl, windowDevice.dcl, windowInternal.(d/i)cl, windowInternal2.(d/i)cl, windowOpen.(d/i)cl Other changes are: * deltaEventIO.dcl: - Comments changed: the type EVENTS has become obsolete. The functions OpenEvents and CloseEvents are no longer imported. - Type of StartIO has changed: the EVENTS environment has been replaced by the World. * deltaEventIO.icl: - Implementation of StartIO has changed because of different interface. Internally the EVENTS are extracted from the World environment and replaced at the end. The World environment is placed inside the IOState environment as a new component and extracted at the end. No further changes. - Type Toolbox has been attributed with *. * deltaFileSelect.dcl: - The Files type is no longer imported from StdFile. * deltaIOState.dcl: - StdFile has been imported. - IOState has been declared as an instance of the FileEnv class (defined in StdFile). * deltaIOState.icl: - StdFile has been imported. - Implementation of IOState instance of the FileEnv class. * font.icl: - Import has been extended with menus. - The implementation of the functions to get the default font (DefaultFont) and the available font names (FontNames) were incorrect. The bugs have been removed. - Type Toolbox has been attributed with *. * ioState.dcl: - Two functions to retrieve and store the World environment in the IOState environment have been added (IOStateGetWorld,IOStateSetWorld). - Type Toolbox has been attributed with *. * ioState.icl: - The IOState type has been changed to a record type. An additional field to store the World environment has been added. This change influences the implementation of all IOState access functions. - Type Toolbox has been attributed with *. - Syntactic changes. * windowDef.dcl: - Last newline character replaced. * windowDevice.icl: - Module StdChar has been imported. - Type Toolbox has been attributed with *. Object IO Examples 1.0 * compare * compare.icl: - openfilepair has been changed because fopen (StdFile) returns a triple instead of a tuple. * gui utilities * Help.icl: - sfopen macro added because fopen (StdFile) returns a triple instead of a tuple. This macro is used in the function readInfo because there fopen is used in a context where a tuple result is expected instead of a triple result. * simple database * database.icl: - fopen2 macro added because fopen (StdFile) returns a triple instead of a tuple. This macro is used in the function ReadDataBase,SaveRecords because there fopen is used in a context where a tuple result is expected instead of a triple result. - K has been renamed by const (ShowRecords). - remove has been renamed by the StdList function removeAt (DeleteRecord,AddRecord, delete). - UpdateDbDomain did not change the look of the view window. This bug has been repaired. - I has been renamed by id (radioitems). * listextensions.(d/i)cl: - insertAt and updateAt have become obsolete because they are now available in StdList. * talk * talk.icl: - K has been renamed by const (talk). ObjectIO 1.0 Of many modules the only difference is the uniqueness attribution of type Toolbox to *Toolbox in type definitions of functions and data types. This occurs in the following modules: controlclip.(d/i)cl, controlcreate.(d/i)cl, controlframe.(d/i)cl, controlinternal.(d/i)cl, controlkeyfocus.(d/i)cl, controllayout.(d/i)cl, controlmousedown.(d/i)cl, controlmousedown1.(d/i)cl, controlselectstate.(d/i)cl, controlshow.(d/i)cl, event.(d/i)cl, iostate.(d/i)cl, memoryaccess.(d/i)cl, menucreate.(d/i)cl, menudevice.icl, menuinternal.icl, menuitems.(d/i)cl, picture.dcl, regionaccess.(d/i)cl, scheduler.dcl, scrapaccess.(d/i)cl, StdClipboard.icl, StdFileSelect.icl, StdMenu.icl, StdMenuElement.icl, StdPicture.icl, StdTime.icl, texteditaccess.(d/i)cl, windowcreate.dcl, windowcursor.dcl, windowdevice.(d/i)cl, windowdispose.(d/i)cl, windowdraw.(d/i)cl, windowinternal.icl, windowkeyio.icl, windowresize.(d/i)cl, windowselectstate.icl, windowsize.icl, windowupdate.(d/i)cl, windowvalidate.(d/i)cl, world.(d/i)cl Other changes are: * commondef.dcl: - Type Toolbox has been attributed with *. - The functions I and K have been added because they were previously available in StdFunc but have been renamed as id and const respectively. * commondef.icl: - Type Toolbox has been attributed with *. - The functions I and K have been added because they were previously available in StdFunc but have been renamed as id and const respectively. * font.dcl: - Module StdFunc no longer imported. - Macros AppFontID,SysFontFam, and SysFontSize no longer exported. - Functions accessfonttoolbox and fontscalenumerdenom no longer exported. - Type Toolbox has been attributed with *. * font.icl: - Error in local function getstringwidths (getfontstringwidths - measurestringwidths) removed: the size argument of QStdTxMeas was 1 rather than the size of the String to be measured. - Type Toolbox has been attributed with *. * layout.(d/i)cl: - Strictness annotation added at the record fields 'ipCorner' and 'cpCorner' of the types ItPos and RCPos respectively. * picture.icl: - Type Toolbox has been attributed with *. - setpicturefont and setdefaultfont use GrafPtrSetFont instead of a local function to store new font information. - Syntactic changes. * scheduler.icl: - Type Toolbox has been attributed with *. - Syntactic changes. * StdControl.icl: - Type of record field 'wTb' of record WState has been changed from !.Int to !.Toolbox. * StdControlClass.(d/i)cl: - The type PSt and IOSt are imported. - Type of class member controlToHandles changed from controlToHandles:: !(cdef .ls .ps) -> [ControlState .ls .ps] to controlToHandles:: !(cdef .ls (PSt .l .p)) -> [ControlState .ls (PSt .l .p)] This change is necessary to allow programmers to define their own controls with predefined callback functions. These usually have type (IdFun (PSt .l .p)), which is less general than (IdFun .ps). * StdControlReceiver.icl: - Type of controlToHandles member function has changed (see StdControlClass). * StdFont.icl: - Module quickdraw no longer imported. * StdTimer.dcl: - Error in previous compiler caused the following wrong instance declaration to be approved: instance openTimer (Timer t) ... It is now replaced by the correct: instance Timers (Timer t) ... * StdTimer.icl: - Previous change also incorporated. - Type Toolbox has been attributed with *. * StdWindow.(d/i)cl: - The first argument of controlSizes has been changed from (cdef .ls .ps) to (cdef .ls (PSt .l .p)) because of the change of the Controls class member function controlToHandles (module StdControlClass). * windowaccess.(d/i)cl: - Type Toolbox has been attributed with *. - Syntactic changes. * windowcontrols.icl: - Because of the change of the Controls class member function controlToHandles (module StdControlClass) the arguments of type (cdef .ls` .ps) have been changed to (cdef .ls` (PSt .l .p)). - Type Toolbox has been attributed with *. * windowcreate.icl: - The formerly exported macros from font are no longer imported. - Type Toolbox has been attributed with *. - Syntactic changes. * windowcursor.icl: - Type Toolbox has been attributed with *. - Syntactic changes. * windowhandle.(d/i)cl: - Strictness annotation added at the record fields 'radioItemPos' and 'checkItemPos' of the record types RadioItemInfo and CheckItemInfo respectively. * wstate.(d/i)cl: - Strictness annotation added at record fields 'dItemPos`', 'radioItemPos`', and 'checkItemPos`' of record types DItemHandle`, RadioItemInfo`, and CheckItemInfo` respectively. Clean Integrated Developing Environment (Mac & Windows) Differences in the Clean Integrated Developing Evironment version 1.2.4 to version 1.3. For more information on the new options consult Clean IDE's online help (Windows->Help...) Preferences File & Project Files (.prj) ---------------------------------------- These files have a new format, old files will be converted and a copy will be saved as ' old' Editor ------ The editor can now read and write files with all new line conventions (Mac, Dos, Unix). The new line convention can be changed in the Format dialogue box. Shift Left & Shift Right new commands (warning: undo is not possible for these commands) Project ------- Set Main Module is now performed without a confirmation dialogue Open Project When a project is open and another project is opened by double clicking it in the Finder (Mac) / Explorer (Windows) the IDE asks if the old project should be closed Options ------- Clean Compiler New profiling options Link Options New dialogue to add object files and libraries to a project Application New option to write the error diagnostics to a file New profiling options Window 95/NT specific --------------------- There is a program (change_registry.exe) to associate file extensions (.icl, .dcl, .abc, .prj) with the Clean IDE. Drag&drop a file to the Clean IDE application icon opens a new instance of the Clean IDE and opens the file Code Generation dialogue: removed Check Stacks option, because stack checks are not implemented Various bug fixes =======================================================