Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
How Objective-C messaging works (danie.lt)
30 points by DanielTomlinson on Aug 3, 2013 | hide | past | favorite | 23 comments



I agree. This post isn't the best explanation and is riddled with grammatical errors that caused me to reread sentences multiple times. Regardless of the age of the author, if you put up a blog post that is supposed to explain a concept to other people, it needs to be well thought out and proof read.

Mike Ash is an excellent example of how to write blog posts about how things work


Also, Mark Dalrymple series http://blog.bignerdranch.com/author/markd/


0xreadbook is not hexedecimal and disqualifies this whole post from any kind of intellectual redemption.

Try 0xDEADBEEF,0xBAADF00D, or any constant listed here: http://en.wikipedia.org/wiki/Hexspeak


I stopped reading when I saw `i = 0xreadbook` and `typdef`. There are typos and there are fundamental misunderstandings -- not sure where these lie


I'd probably avoid 0xB16B00B5.


I'd probably multiply and sum...


That's a bit overpedantic. It's a mnemonic for remembering the way the bytes are arranged in memory: "Ok, Bo: add re".

Nobody complains that r, o, y, g, b, i, and v aren't actual colors, do they? Other than you, I mean.

http://en.wikipedia.org/wiki/List_of_mnemonics


r=red, o=orange, y=yellow, etc.. No problem there.

What does K equal in hexadecimal? Well, it isn't defined for hexadecimal. K=20 is only defined in Base 21 and above.

Other than me? Hah, nice cheap shot, pole ;-)


The letters need only illustrate the positions and be memorable. No hex is required for this purpose.

Edit: The 0x communicates that the mnemonic is illustrating base 16, so your objection below is not valid.


Endian-ness changes when the base changes. For a clear explanation, actual hex is needed.


A byte is not a byte if its value exceeds 255.


What is "0xreadbook" in the context of a 32-bit int supposed to mean? Is the author just trying to be cute, or is this some sort of nonstandard representation of hexadecimal digits that I need to read up on?


It's the author being cute I think. I've never heard of it either.


Yes dude,

it just an example hexadecimal representation. Don't take everything so literally...


Literally? A tutorial for noobs should be literally accurate -- throwing around non-proper representations is just a cloudy lazy explanation.


appreciate, don't hate


It's a reasonable comment. I got to "0xreadbook" and found it rather difficult to continue. If you're trying to explain stuff, you need to get these things right. You wouldn't provide something like "LET STORE OF VALUE X CONTAIN LITERALLY 15 AS INTEGER" as example C code, right? Because it's not even C. In fact it's just nonsense. So I fail to see why "0xreadbook" is a valid example hex value... because it's not even hex.

Bizarrely, despite the author's apparent confusion about this basic concept, the rest of the piece seemed kind of OK, and he even got the hex representation of 1.f correct.

A much better example hex number is 0x12345678. Every digit is different, and it's actually a valid number.


Appreciate misinformation? No thanks.


it just an example hexadecimal representation

It's not hexadecimal, so what's your point?


Well at least the 16 year old tried?


Don't do that. Criticize people on their work, not on their personal attributes.


Hey man, that's kind of mean.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: