Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversion between byte and Integer is not sign-proof #720

Open
FroMage opened this issue Aug 15, 2012 · 4 comments
Open

Conversion between byte and Integer is not sign-proof #720

FroMage opened this issue Aug 15, 2012 · 4 comments

Comments

@FroMage
Copy link
Member

FroMage commented Aug 15, 2012

I'm pretty sure we want bytes to appear as unsigned bytes in Ceylon, so when converting from byte to Integer we should make sure we get a value between 0:255 rather than the current -127:128 (give or take 1)

@FroMage
Copy link
Member Author

FroMage commented Oct 1, 2012

Moving to M5

@FroMage
Copy link
Member Author

FroMage commented Feb 27, 2013

I tried to do this, but it isn't trivial and would require more testing, and we have a relatively easy workaround so I would move it to M6.

@FroMage
Copy link
Member Author

FroMage commented Oct 31, 2013

I think the discussions around the usefulness of better support for bytes are for 1.2, so moving this one.

@quintesse
Copy link
Member

Besides I was thinking, couldn't we support conversions from Integer in the range of -127:255? That way you could convert both signed and unsigned numbers. (leaving this comment for when we pick this up again)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants