JarrettBillingsley
Joined: 20 Jun 2006 Posts: 457 Location: Pennsylvania!
|
Posted: Mon Oct 08, 2007 9:42 am Post subject: MiniD 1.1 -- Fixed supercalls, speed boosts, CLI stuff |
|
|
This is actually MiniD 1.1, as the fix to classes makes this somewhat incompatible with old precompiled modules, and vice versa.
OK, so the tagging system was a pain to keep up, since I've been fixing some minor issues and having to re-tag the thing over and over, so now I'm just directing people to download a certain revision in the trunk.
Added/Removed
- Added minid.compiler.compileExpression to compile a single expression. eval() (in both MiniD and D) now use this and will give better errors because of it.
- Added the baselib bindContext() function, to do what curry() couldn't.
- Added an overload of MDState.callMethod that takes an MDString as the method name.
- Added MDState.callDepth().
- Added MDState.cat() and MDState.catEq(). Don't know how I missed those before.
- Added constant folding for three-way comparison expressions (the <=> operator) in the compiler.
- Moved the guts of MDCL into minid.commandline.CommandLine, as per the suggestion by teqdruid (John).
- Added the ability to the commandline to enter "=expression" to just evaluate the expression and print it out, much like the Lua CLI, also as per the suggestion by teqdruid.
Changed
- MDCompileExceptions now have a public atEOF member to indicate whether they were thrown because of an EOF condition or not. To go along with this, minid.compiler.compileStatements no longer takes an out atEOF parameter.
- Some speed improvements in the interpreter, notably in math, comparisons, and accessing locals. These will probably provide a slight boost in speed for other code as well.
- The exception traceback mechanism has been moved into MDContext, and is now a per-context entity. This means to access the traceback, you now access the traceback methods through a state's context, rather than through a static method of MDState.
Fixed
- Integer and character comparison should now work properly in all cases. I used to use (a - b) as the comparison value for them, but that gives erroneous results if the difference between a and b is sufficiently large.
- Updated the benchmark MiniD scripts to use tango-style formatting.
- Fixed compilation on non-Windows, where oslib.d would fail to compile because some Windows-only code wasn't versioned correctly.
- Changed the way classes are created and how supercalls work, to fix ticket 3 (supercalls in class hierarchy more than two deep causes infinite loop).
Sorry I haven't been working on / maintaining MiniD that much over the past couple of months. I've been rather busy with school; I didn't expect to have this much work for so few classes. I have been making commits, though, and if you check in the v2 branch you'll get a sneak peek at what might come in MiniD 2.
Last edited by JarrettBillingsley on Sat Nov 24, 2007 9:49 am; edited 1 time in total |
|