Version 0.6.2 released

3 views
Skip to first unread message

Gaëtan de Menten

unread,
May 22, 2013, 5:16:54 AM5/22/13
to liam2-a...@googlegroups.com

I am pleased to announce that version 0.6.2 of Liam2 is now available.

This release introduces a single fix related to copying simple fields.
The bug was severe enough that it warranted a release all by itself. All
users are encouraged to upgrade. See the explanation below.

This new release can be downloaded on our website:
http://liam2.plan.be

As always, *any* feedback is very welcome, preferably on the
liam2-users mailing list: liam2...@googlegroups.com (you need to
register to be able to post).

Fixes:
------

* fixed storing a copy of a (declared) field (without any modification)
in a temporary "backup" variable. The temporary variable was not a copy
but an alias to the same data, so if the field was modified afterwards,
the temporary variable was also modified implicitly.

As an example, the following code failed before the fix:

# age is a field
- backup: age
# modify age (this also modified backup!)
- age: age + 1
# failed because "backup" was equal to "age"
- assertEqual(age, backup + 1)

This only affected assignment of "pure" fields, not expressions nor
temporary variables, for example, the following code worked fine
(because backup stores an expression, not a simple field):

- backup: age * 1
- age: age + 1
- assertEqual(age, backup + 1)

and this code worked too (because temp is a temporary variable, not a
field):

- temp: age + 1
- backup: temp
- temp: temp + 1
- assertEqual(temp, backup + 1)

--
Gaetan de Menten

Federal Planning Bureau
Economic Analyses & Forecasts
Avenue des Arts, 47-49 | 1000 Brussels
tel. +32 (0)2 507 7459
fax +32 (0)2 507 7373
email : g...@plan.be | www.plan.be


----------------------------------------------------------------------------

Disclaimer: please see "www.plan.be/disclaimer.html"

Please consider your environmental responsibility before printing this email

----------------------------------------------------------------------------

Reply all
Reply to author
Forward
0 new messages