I expected your reason for wanting to change the meaning of private
was that you wanted the stricter behavior without having to break backward compatibility. I figured you were producing a library that you wished to be usable with Delphi 7 and prior, which don't have the strict
modifier.
But if that's not your reason, then I don't think you've got much to work with. You can convert all your private
code to strict private
pretty easily with a simple script.
perl -i.bak -pe 's/(?<!\bstrict )\b(private|protected)\b/strict $1/ig' *.pas
That takes any private
or protected
that isn't already strict and puts strict
in front of it. It modifies the files in-place. (Beware; it may insert "strict" into string literals, too.)
So anyway, I don't think we're going to see private
become strict anytime soon. Doing that could break old code, and there's not really much practical gain from it. It lets purists have "more pure" code, but they can already have that simply by using strict
. I think that if we were ever going to have "default strict" visibility, then the time for the change was when strict
was introduced in the first place. But as things are today, we already have a way of getting strict visibility specifiers, so there's no need for another change.