A couple of questions

Recommended Posts

Suudy    122
We are looking for a couple of features, that we aren't sure are supported. Any info on these (soon to be, or requires us to implement)? First, we'd like to initialize arrays in a C-like fashion: uint[] x(3) = { 0xdeadbeef, 0xfeed0123, 0x01234567 }; Though this doesn't work. I don't see in the documentation (or through experimentation) any way other than: uint[] x(3); x[0] = 0xdeadbeef; x[1] = 0xfeed0123; x[2] = 0x01234567; Any info? Also, the bitwise complement doesn't seem to work on uints. For example: x = 0xfeed0123; x = ~x; Fails with "Illegal operation on this datatype." Why isn't is supported for uints, ints, etc? Thanks, Suudy

Share on other sites
Suudy    122
I should have mentioned the version. We are using version 2.2.

Thanks,
Suudy

Share on other sites
poss74    193
not sure about the bitwise complement stuff, but shouldn't the declaration be:

uint[] x = { 0xdeadbeef, 0xfeed0123, 0x01234567 };

Share on other sites
WitchLord    4677
Initialization lists haven't been implemented yet. I plan to implement them some day, but the priority is quite low at the moment. If you'd like to contribute with the implementation I'd be grateful.

That the bitwise complement doesn't work for uint, ought to be a bug. I'll investigate this and keep you updated.