flat assembler
Message board for the users of flat assembler.
Index
> Main > multiple operator bug |
Author |
|
bitRAKE 18 Jun 2009, 04:47
Imagine some of those expressions might result from macro expansion, and hence are valid input.
|
|||
18 Jun 2009, 04:47 |
|
SFeLi 18 Jun 2009, 06:34
Code: 3-+6 = 3 - (+6) ; Binary -, unary +. C allows this too. 3++6 = 3 + (+6) ; Binary +, unary +. C doesn’t allow this, ; but allows 3+ +6. Fasm doesn’t have unary ++ ; operator, so it is ok to allow this without ; spaces (as well as 3--2 etc.). |
|||
18 Jun 2009, 06:34 |
|
geppy 18 Jun 2009, 06:48
hell, regardless what C creators think there is no way you can persuade me that to be acceptable. There is too much assumption has to be made.
What about multiplication and 3 in a row operators my C expert? mov eax, 8*-+7 Last edited by geppy on 18 Jun 2009, 07:01; edited 1 time in total |
|||
18 Jun 2009, 06:48 |
|
Tomasz Grysztar 18 Jun 2009, 07:01
geppy wrote: What about multiplication my C expert? Well, in fact, "i*-+8" is going to work in C, too. Because both "-" and "+" are unary operators, you are free to use them as much as you want. Moreover, "i*+-8" is going to work in C, too - but it's not working in fasm, because fasm accepts "+" only immediately next to number. So, if there's any bug to fix, it's to make "+" a fully supported unary operator, just like "-" is. Though I don't think it's really so important. |
|||
18 Jun 2009, 07:01 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.