This is valid (x = (* mat) ++;)?

0
(x = (*mat)++;)

If it is valid, explain to me why and how it will work.

    
asked by anonymous 10.09.2017 / 23:48

1 answer

3

This is not valid, you may not have a statement within parentheses . Because? Because the language specification (old, new ones are paid for) says so. They could allow, but there is no advantage in this and eventually something could conflict with the evolution of language. The idea is not to let you do crazy things. Without the external parenthesis and with the proper code around it would be valid. Anyway analyzing an isolated code does not make sense at all.

When you want to know if something is valid, write to a file and see if the compiler accepts it.

    
11.09.2017 / 00:01