News for hackers. Stuff that matters.
Re:Main is usually a function, so when is it not? (2015) by FranchuFranchu on Monday June 14, 2021 @12:39PM (#27504741)
Why does he add semicolons at the end of the assembly lines?
Re:Main is usually a function, so when is it not? (2015) by actually_a_dog on Monday June 14, 2021 @01:07PM (#27505142)
They're not necessary, so I suspect some combination of reflex, consistency for consistency's sake, or, possibly that they were added automatically by his editor/IDE at some point.
Re:Main is usually a function, so when is it not? (2015) by Taniwha on Monday June 14, 2021 @04:10PM (#27507636)
They allow you to put multiple instructions on the same line - in this case you must either have ';'s or '\n's in the string - having both doesn't break stuff, I guess it's more belt and braces
Re:Main is usually a function, so when is it not? (2015) by wtetzner on Monday June 14, 2021 @12:48PM (#27504885)
Not sure. I guess it shouldn't hurt anything though, since semicolon is the comment character.
Re:Main is usually a function, so when is it not? (2015) by Taniwha on Monday June 14, 2021 @04:06PM (#27507600)
depends on the assembler, in some assemblers ';' allows you to put multiple instructions on the same line