ZBasic Compiler Revision History

v1.4.1 - 17 October 2006
-------------------------
- Fixed a code generation problem where not all of the elements of an array of
  structures got initialized properly.  This was only an issue for structures
  that contained String members.


v1.4.0 - 16 October 2006
-------------------------
- Added support for Oak Micros' ZX-24e and ZX-24ae.

- Added the ability to invoke tasks with parameters.

- Added support for specifying a task's stack by giving its address.

- Added code to output the target device in the .zxb file.  This allows the
  downloader to detect a mismatch between the generated code and the target.

- Added built-in constants Pin.RedLED and Pin.GreenLED for the applicable devices.

- Improved the code optimization to reduce or eliminate successive type conversions.

- Changed to allow Based and Alias variables to be declared as arrays without
  specifying the dimensions.

- Fixed a problem with missing temp variables for strings being passed to
  system functions that are implemented in "user code".

- Fixed a problem with code generation for exponentiation.  Added an optimization for 2^x.

- Fixed some problems with using an enumeration as a structure member.  Also, added
  detection for attempting to use different enumeration types in an equality test.

- Fixed a code generation problem that would occur with an Exit Do inside a Case
  with no statments following the Do.


v1.3.2 - 07 September 2006
-------------------------
- Fixed an internal error that would occur when encountering code that increments or
  decrements a Single variable, e.g. f = f + 1.0 and equivalent variations.


v1.3.0 - 21 August 2006
-------------------------
- Added Right() and Left() string functions.

- Added the ability for WaitForInterrupt() to await an analog comparator interrupt.

- Added compile-time parameter validation for WaitForInterrupt().

- Fixed an error in resolving enumeration member names.

- Fixed an optimization error where assignments inside an If statement
  were sometimes erroneously being deemed useless.

- Fixed a code generation error that caused integral exponentiation results to be
  truncated rather than rounded.


v1.2.7 - 24 May 2006
-------------------------
- Fixed an error in the code generated for Mid() when it appears on the left of an assignment.


v1.2.4 - 11 May 2006
-------------------------
- The third parameter of Mid() is now optional (compatible with VB).

- The first parameter of StrAddress() and StrType() are now ByVal.

- Fixed a problem with underscore continuations in in-line initializers for String types.

- Fixed an error in the code generation for the & operator when used in a parameter value.


v1.2.0 - 04 May 2006
-------------------------
- Added support for structures and expanded the With statement to support use with structures.

- Added new System Library routines: GetDayNumber(), GetDayOfYear(), GetQueueStr(), StrCompare(), StrFind().

- Added optional parameters to DefineCom(), GetDate(), GetDayOfWeek(), X10Cmd()

- Modified I2CCmd() and SPICmd() to allow the count parameters to be 16-bit values.

- Added support for multiple statements per line with a colon separator.

- Added support for underscore line continuation within in-line block data initializations.

- Added Register.CPUFrequency and Register.RTCTickFrequency.

- Added support for defining enumerations, Program Memory data items and Persistent data items within procedures.

- Modified the syntax of the CallTask statement to allow an unquoted task name.

- Added names for 16-bit registers, e.g. Register.TCNT1.

- Improved the optimization of code generated for array access, especially with constant indices.

- Fixed 'Option C.0 ...' that was broken when structure support was originally added.

- Fixed some miscellaneous optimization/code generation problems.

- Fixed an implementation error where multi-dimensioned and non-1-based arrays could not
  be passed to System Library routines as they can with BasicX.

- Fixed a problem with #if/#elseif conditional evaluation.


v1.1.18 - 30 March 2006
-------------------------
- Fixed a problem where code was being generated referencing a variable whose
  most recent assignment had been optimized away.

- Modified Chr() to accept any integral parameter, resolving a BasicX incompatibility.

- Chr(0) was not being handled correctly by the optimizer.

- Fixed an error in the code generation for decrementing an integral value.


v1.1.11 - 28 February 2006
-------------------------
- Added support for spaces/tabs and/or comment following a line continuation
  underscore.

- Fixed an access violation that occurred with SizeOf() when used as a parameter.

- Fixed a problem with pin name constants like C.1.


v1.1.10 - 23 February 2006
-------------------------
- Implemented task stack size estimation and checking.

- Added Register.CodeSize, Register.RamSize, Register.RamUsed.

- Modified CStrHex() for smaller code size and smaller stack usage.

- Based variables were erroneously considered to be uninitialized.

- Deleted Port D bits 0 and 1 from the table of valid pins for the ZX-40.

- Persistent variables were erroneously being allowed to be passed by reference.

- Module level bounded strings, fixed length strings and enums with the volatile
  attribute weren't being treated as volatile.

- Added code to allow Enum types to be based.

- The --calls-list option didn't work; the --called-by-list option caused both
  lists to be generated.


v1.1.5 - 23 January 2006
-------------------------
- Added information on task and procedure stack use to the .map file.

- The opcodes generated for shifting Integer and UnsignedInteger values were swapped.


v1.1.4 - 20 January 2006
-------------------------
- Fixed problems with For loops having unsigned index variables.
  Also, in BasicX compatiblity mode a step value of -1 was not being accepted.

- The compiler did not allow SizeOf() to be used with return values or aliases.

- Modified the compiler to require that both the data count and the data pointer
  be zero to constitute the special case representing "no data being supplied"
  for the System Library routines I2CCmd() and SPICmd().

- Added support for RunTask().  This requires VM v1.1.2 or later.

- Using the DataAddress property with Bit and Nibble variables caused an
  internal error instead of generating the appropriate error message.

- Re-enabled an optimization for expressions like i = i + 1 so that they use
  a special increment/decrement opcode where possible.

- Added support for based variables.


v1.1.0 - 13 December 2005
-------------------------
- Added support for IIf(), SetBits() and ToggleBits() System Library routines.

- Added some additional optimizations: conditional expressions like (b = 0)
  and (b <> 0) now use the boolean conversion opcodes.  Also, (b And &H01)
  and (b And &H0f) now use the bit and nibble masking opcodes, respectively.

- Added the ability to specify a limit to the code size and have the compiler
  report an error if it is exceeded.  See --code-limit= and Option CodeLimit.

- Added support for plus and minus signs in Program Memory initializer values.

- Fixed a problem where Program Memory initializers in BasicX mode generated
  an error message saying that they were illegal in-line initializers.

- Fixed an optimization problem with Do Until and Do While.  If the expression
  value was a known constant at the top of the loop, modifications that might
  be made within the loop were not properly being taken into account.


v1.0.0 - 18 November 2005
-------------------------
- Added the CStrHex() and CloseWatchDog() System Library routines.

- Added support for specifying an include path, see --include-path.

- Added preprocessor symbols, __LINE__, __FILE__, __DATE__ and __TIME__.

- Added support for #notice.

- Added support for using quoted strings to specify data values in Byte
  Program Memory initializers.

- Modified pin value analysis to allow a zero value for OpenSPI().

- Added a few more entries to the keyword table including Based, Declare and Type.

- Removed -c as a synonym for the --no-code option, making it available
  for a different use in the future.

- Added missing support for aliases based on parameters and return values.

- Fixed some miscellaneous optimization problems.

- Added some missing opcodes in the disassembler table.

