i think midlet pascal does that, but it's not opensource (yet)