Pharo Rules: an up-to-date report
For the last three months I have been working on various things focusing on improving the Pharo programming environment. During this period I have worked on different topics, and have written articles about some of them, but one of the most major things I have been doing all this time is updating and converting rules in Pharo. Below is a relatively short summary of what I have accomplished so far.
The types of the rules I have been working on converting are RBBlockLintRule, RBParseTreeRule, and RBTransformationRule. I did about 90 rules, which means there are still around 20 rules to go — just 15% of the task left. Converting most of these rules was quite easy — see what they do, and how they do it, determine how to rewrite them in a more comprehensive and easy-to-read way (sometimes following a set pattern, sometimes having to come up with the solution on my own), update commentary, hints, highlighting, and so on so forth. But a lot of the rules were quite complex, too. Often I would have to rewrite the whole rule using another type of implementation whatsoever. For example, for RBBlockLint rules I did quite a few node versions (about one particular example you can read here and here), for RBParseTree and RBTransformation rules with which I have been busy this month, I had to make a lot of rewrites as well.
So the rules I have converted are working much faster than the original ones, and most of them are also more effecient at finding methods that violate those rules. And these changes will be soon integrated in the new Pharo version.
In-between I have also worked on the banning of rules (the article about it is here), and also looked at some Match Tool Tutorials. There is still some work to be done in rule converting, and I will be doing it at the same time as I will be working on developing a Match-Rewrite Tool.