The case for strict parameter types

While refactoring a bit the way some “special” functions were handled in DWScript, I came about a case where the compiler started accepting strings as Math functions parameters.

While this comes naturally as an “interesting” side-effects of automatic typecasts, it left a feeling of “wrongness”, accepting literal code like Abs(“foo”) and then failing at run-time is asking for trouble.

(more…)

Delphi XE6 32bits and Scimark

8087In a Google+ comment to my recent article about inlining in XE6, Leif Uneus posted results from Scimark.

It appears that XE6 is about 30% slower than previous versions at least from XE5 to XE for 32bits floating point.
Note that Scimark does not make use of inlining, but does make heavy use of floating-point computations, loops and arrays.

Edit: issue discussed here was reported in QC 124652 (now marked as resolved)
(more…)

Introducing “unit namespace”

DWScript now has a new “unit namespace” feature, which aims at killing several birds with one stone:

  • supporting “classic” namespace as found in Java or .Net
  • supporting aggregate namespaces and conditional units
  • supporting unit deprecation and splitting with backward-compatibility