If we can say
type
Xtype = object
Ytype = object
instead of
type Xtype = object
type Ytype = object
then shouldn't we be allowed to say
func
f() =
42
g() =
99
There are probably more examples where blocks could/should be allowed.Because you don't have
import
module1
module2
?But we do have,
import module1, module2
when grep-ing I find it quite useful to always have proc/func/template/macro before the proc name so I can easily distinguish between definitions and call sites.
And what Araq said about the AST. Working with type sections or const/let/var I always opt to create a separate one when generating code because it's easier. And for parsing it would require supporting the 2 kinds of definitions.