15
07/10
07:06
What if….?
What if C#….
- had no properties?
- had only private fields?
- fields were readonly by default?
- had no mutable static fields?
- had no static methods or static classes?
- prohibited passing null as method parameters?
- integrated specs/test with code, in the same file?
- only allowed one class per file?
- prohibited nested classes?
- had syntax distinguishing between class dependencies and notifications with special syntax?
- enforced command-query separation from methods?
Some of these ideas are almost unworkable, some are fundamental to the cause and some are just “my style”. In a future post I’ll go over each in detail and see how they can be implemented–maybe I’ll just hack a few FxCop rules together and be done with it.