-
Notifications
You must be signed in to change notification settings - Fork 266
Description
I have a bit of a concern about the postfix type
and namespace
keywords, both about consistency and implementation caveats.
The main gist of my concern is that with postfix type
keyword, a type's parents cannot be defined as they are in syntax 1, as column is being used for the keyword.
Of course it can be done via Java-style extends
(or similar) keyword. Or via a second column after the type
. But that just seems like introducing visual noise into the syntax for the sake of having a postfix keyword.
Another concern is how would template declarations and concept requirements work, would the template/requires keywords also come after the column like this?
my_type : template<typename T> requires (X) type
or like this
my_type : type template<typename T> requires (X)
This, at least to me, seems a bit noisy as well.
And finally - consistency: this way there will be prefix keywords (i.e. if
, for
, etc.), postfix keywords without a column (ex. noexcept
) and postfix keywords with a column (type
). This, again, seems to me like additional syntactical noise for the sake of "using the shiny postfix".
Are there any valid reasons for the postfix keywords for types/namespaces that i just dont see? How would inheritance, templates, etc. work with the postfix keywords?