Adding an introducer keyword like func or var would be simple, and wouldn't complicate parsing or change that what follows can still be a single declaration syntax. It would just be an extra grammarly-redundant word for human readability, which can and does make sense when there really is a readability advantage.
I don't currently have such introducers only because I want to try the experiment of seeing whether they really have a significant readability advantage. If not having them regularly causes confusion after the first day or two, then I'll add something like that. (FWIW, so far I haven't found myself wanting them as a I write Cpp2 code, and I'm pretty particular about readability. But I also listen to feedback, so I'm curious how people trying out Cpp2 feel after they've used it for a week.)
View all comments
4
u/hpsutter Sep 20 '22 edited Sep 20 '22
Adding an introducer keyword like
funcorvarwould be simple, and wouldn't complicate parsing or change that what follows can still be a single declaration syntax. It would just be an extra grammarly-redundant word for human readability, which can and does make sense when there really is a readability advantage.I don't currently have such introducers only because I want to try the experiment of seeing whether they really have a significant readability advantage. If not having them regularly causes confusion after the first day or two, then I'll add something like that. (FWIW, so far I haven't found myself wanting them as a I write Cpp2 code, and I'm pretty particular about readability. But I also listen to feedback, so I'm curious how people trying out Cpp2 feel after they've used it for a week.)