This might be caused because 2<<8 is too big for the receiver.
But if so, why? I thought that the RESULT of the initializing code must be in the bounds of the receiving type?
Rust never casts between integer types implicitly. If you want to perform a calculation using one type and then cast the result to another type, you must include an explicit cast. For example:
Exactly! I mistakenly thought of 2 to the power of x and used x for shifting which is obviously wrong and (1<<8) -1 is indeed the right way to do this. Thx!
Also, this precedence trips me up; didn't expect this.
Would be good is Rust (as Ada would complain about not using parenthesis in such cases!