Menu

The Pythonizer / Blog: Recent posts

Project Files for the Pythonizer project

I have just added Pythonizing1_0ProjectFiles.zip and Pythonizing1_1ProjectFiles.zip. These are dumps of source code, test files, syntax rules and my learning journal for each version of the project. If you want to find out why I wrote the Pythonizer in the first place and my trials and tribulations in developing it, this is the place to look.

Posted by Richard Bosworth 2022-05-30

New: version 1.1 of the Pythonizer

The new version of the Pythonizer has a few enhancements:

  1. Recognition of non-static methods in the Java source and conversion to Python methods. This was a grave omission in the original Pythonizer, but to tell the truth, it's been a long time since I wrote a method in Java. I now tend to write procedurally, so the legacy code for which the Pythonizer was designed only contained static procedures. This omission has now been corrected: all non-static procedures are given an extra "self" parameter, and Java "this" is translated to Python "self".
  2. The treatment of non-public names has been improved. These now all get an initial underscore, as per PEP8. Because the Pythonizer allocates attributes to names irrespective of their position in the source file, this may result in a public name that duplicates a non-public name being underscored. Well, tough luck! A little editing on the Java source will fix this.... read more
Posted by Richard Bosworth 2022-05-30