
Dear Michal Simek,
In message 4E647722.9080602@monstr.eu you wrote:
I can only offer you a solution that seems acceptable to me.
seems?
Well, yes. As mentioned, I'm not happy with the propsal myself, but as long as I cannot come up with any better one it would be unjust to demand it from you.
This obviously doesn't mix well. If there is no better way
of doing this, I'd still prefer deriving the index from the offset in a struct than deriving the address from an offset - the intention is to enable the compiler to perform type checking, which is impossible with a typeless base+offset address.
I understand the reasons for that but I can't see any elegant way how to do so.
Well, I just proposed one way - not elegant indeed, but I'd be willing to swallow that.
You mean that array of structs, right?
No. I mean the text above: I'd rather derive the index from the offset in a struct instead of deriving the address from an offset (but I have to admit that I don't see an elegant way to implement this yet).
Best regards,
Wolfgang Denk