-
Notifications
You must be signed in to change notification settings - Fork 147
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
Why do we need an extra dash in 00-
?
#3546
Comments
@maxonfjvipon Can you help with this please? |
@volodya-lombrozo without the dash, we won't be able to differentiate |
@yegor256 Sorry, I can't digest it. I'm talking about bytes object: <o base="org.eolang.bytes">00-00-00-00-00-00-00-1A</o> Do you have an ability to save integers to bytes object? <o base="org.eolang.bytes">42</o> <!-- (integer, 8 bytes) --> Looks like a crutch to me. |
@volodya-lombrozo I believe, it's some technical limitation in our XSL processor. @maxonfjvipon am I right? |
@volodya-lombrozo it's just a bit convenient that bytes XMIR looks the same as they are in original EO and there's no need to make some extra unnecessary manipulations. Also when we print XMIR to EO, at the certain point of time XMIR may contain strings and numbers after unhexing. And here there's no way we can differentiate one byte from integer number if byte does not end with dash |
@maxonfjvipon I understand, that it is done only for development convenience:
In this case it makes development easy (only for you, btw), but confusing for other people who works with XMIR. In reality, we spend unnecessary space and confuse readers. As for this:
Actually you have |
@yegor256 @maxonfjvipon Can we just remove it? |
@volodya-lombrozo I think we can't, at least for now. It really simplifies development because you don't need to:
All you need is either correct EO/PHI grammar if you start from EO/PHI, or handle dashes if you start from XMIR |
I believe the convenience of development main |
@maxonfjvipon I don't against dashes in bytes. I agains the last dash in |
@volodya-lombrozo the tailing dash is part of the syntax in EO (and phi-calculus). We technically can remove it in XMIR, but this will make XMIR a special case. What for? |
@yegor256 Why the last dash is a part of syntax? What for? |
|
@volodya-lombrozo consider the next EO code:
How to write a one byte |
@maxonfjvipon In EO frontend you might use anything you want:
or
Btw, do you think it's understandable, that
To be honest, It doesn't matter at all, actually. It is a frontend. Why do you carry all this to |
@yegor256 btw, do you agree with this? |
@volodya-lombrozo we won't change the format of bytes/numbers in EO and phi. It's not an option anymore. Then, the question is whether we should have a different format of bytes in XMIR or use the one that we have in EO and phi? I say, we use one format everywhere. I understand that we can use another format (for a number of reasons), but it's better to stay with one format everywhere. My subjective, opinionated, and final decision :) |
@volodya-lombrozo Hello! Thank you for submitting this ticket. Unfortunately, it was not accepted by the team. As per our policy, this results in a deduction of 16 points. While this outcome is disappointing, please don't be discouraged. Your efforts in reporting issues are valuable for improving our project's quality. Moving forward, we encourage you to be more thorough in your submissions. Remember, bug reports are always welcome when properly documented. Keep up the good work! |
From this comment, I can see that if we have a single byte, we should use
00-
. It's confusing. Why can't we just use00
? Does this extra dash have some specific meaning, or are we just wasting extra space?The text was updated successfully, but these errors were encountered: