Live data from Hacker News

How Objective-C messaging works

danie.lt

11–20 of 25 posts

Re: How Objective-C messaging works

#11
post #8
post #6

Earlier quoted context omitted.

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.

Re: How Objective-C messaging works

#13
post #5

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

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

Re: How Objective-C messaging works

#14
post #4
post #2

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?

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

it just an example hexadecimal representation

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

Re: How Objective-C messaging works

#16
post #5

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'd probably avoid 0xB16B00B5.

I'd probably multiply and sum...

Re: How Objective-C messaging works

#17

Try these if you'd like an actual explanation of how Obj-C messaging works. http://www.mikeash.com/pyblog/friday-qa-2012-11-16-lets-buil... http://www.friday.com/bbum/2009/12/18/objc_msgsend-part-1-th...

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

Re: How Objective-C messaging works

#20
post #5

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
Post reply on HN