Sign up ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free.

When I read these lines aloud to someone:



How should the -> and :: be pronounced? Reading the characters themselves in cumbersome and I don't know of any nicknames for them. Being a developer who is used to C-style syntax, I'd like to say "dot", but I'd like something that is easy to say and people can easily understand.

It would also be good to know if there are any pronunciations that have become de-facto standards among teams of developers.

share|improve this question

closed as primarily opinion-based by gnat, MichaelT, Bart van Ingen Schenau, GlenH7, Kilian Foth Jan 27 '14 at 9:23

Many good questions generate some degree of opinion based on expert experience, but answers to this question will tend to be almost entirely based on opinions, rather than facts, references, or specific expertise.If this question can be reworded to fit the rules in the help center, please edit the question.

I'd like to suggest "quadrodot" for "::" – FrustratedWithFormsDesigner Feb 1 '11 at 18:05
Double-colon is the same symbol as "cons" in ML, but since the meaning is totally different, I guess that doesn't work. Too bad, though, since it's a rather convenient name. – Andrew Feb 2 '11 at 2:44
@FrustratedWithFormsDesigner: That sounds much better in languages using "double dot" as the name for "colon" (e.g. German "Doppelpunkt"). – maaartinus Jan 25 '14 at 10:16

10 Answers 10

up vote 3 down vote accepted

-> = "Arrow"

:: = "Dot" if it was in the context of a function definition. Otherwise, "double-colon".

share|improve this answer
Is this just what you call them, or do others to whom you use these terms to use the same pronunciation? – NickC Feb 1 '11 at 17:45
The arrow, yes. "dot" for :: I have only heard in one place (in college between myself and classmates) so that may or may not be common. I don't know what else but "double-colon" to call it if it's anywhere but in the class-function context, but it makes sense there. Anyone who knows C++ will know how to write a function def. – Michael K Feb 1 '11 at 17:53
Guess I should've included that in my answer. It is now. – Michael K Feb 1 '11 at 17:55
@MichaelK, Shouldn't -> be called the dot and :: be called the dot dot? – Pacerier Mar 12 at 7:01

:: is officially called Paamayim Nekudotayim, which translates to 'double colon' (and the wikipedia link should tell you that the technical term is 'scope resolution operator')

Personally I don't read it at all. Don't see the need to.

share|improve this answer
So do you say that out loud? I feel sorry for you, and your coworkers :) "User Manager Paamayim Nekudotayim Get Instance". – NickC Feb 1 '11 at 17:48
@Renesis: If you speak Hebrew, you just might. ;) – FrustratedWithFormsDesigner Feb 1 '11 at 18:05
@Renesis, I enjoy saying Paamayim Nekudotayim, it brightens my day. – zzzzBov Feb 22 '11 at 21:00
@zzzzBov, I can imagine how bad your day is. – Pacerier Mar 12 at 7:02

For the "->" I usually call it "arrow". I, and other's I have worked with, call "=>" a rocket in order to differentiate the two.

As for "::" - I believe that calling it "colon-colon" is clear and not a mouthful.

share|improve this answer
Thanks for bringing up =>, that's interesting. Never heard rocket but it makes sense to differentiate. I have usually said colon colon too, but the repetition and 4 syllables make it sound really awkward to me. – NickC Feb 1 '11 at 17:48
=> in foreach I read as 'for each $array as $key indicating $value'. In array definitions I don't read it. – Mchl Feb 1 '11 at 18:01
@Mchl for some reason I think I read it as "goes to" in that sentence. – NickC Feb 1 '11 at 18:22
+1 I think we can all agree that nobody wants a mouthful of colon. – Adam Lear Feb 1 '11 at 19:45

-> - arrow operator

:: - scope resolution operator.

share|improve this answer
+1 This is the answer. – Ben L Feb 1 '11 at 18:44
@Ben - but is that how you read it? "User Manager scope resolution operator get instance"? Official name is different than pronunciation. – NickC Feb 1 '11 at 19:23
@Renesis, that's a valid point I suppose. In speaking I would probably say something like "Make sure you include User Manager _slight-pause_ Get Instance or it's not going to work." Of course it all depends on the context. Who am I talking to? Do they know the language/codebase? etc. – Ben L Feb 1 '11 at 19:28
@Ben: How about the possessive? Example: "Make sure you include User Manager's Get Instance or it's not going to work" – FrustratedWithFormsDesigner Feb 1 '11 at 19:45
@Frustrated - That work's too, sounds more natural. – Ben L Feb 1 '11 at 20:12

I don't pronounce these at all, not least because it should be clear from context. So I'd say your examples as "controller process" and "UserManager getInstance". If I needed to be painfully obvious, I'd pronounce -> as "arrow", but I've never had any need to pronounce ::, and I've been tutoring CS students for three years.

share|improve this answer

Nice question. I've myself called -> "pointer to" or "call" depending on if it's a pointer to a structure or the calling of a method.

As for the ::, I've never really had a name for that, but I suppose you could say "class member to", so it would read "UserManager class member to method getInstance". Though to each his own I suppose.

share|improve this answer

-> is "point" and :: is "dot".

So customer->buy() is "customer point buy"

share|improve this answer
Do you use this with other people? I like it, if you've found it works in practice I may begin to use this. – NickC Feb 1 '11 at 19:23
Given customer is a class and buy is a method on that class that code means you buy a customer? I think buying customers is illegal in most countries. :) – Elyse Feb 1 '11 at 19:24

I've always called "->" the "gozinta" operator. "::" is just "double colon" to me. No special name. :-)

share|improve this answer
Where does "Gozinta" come from? – NickC Feb 22 '11 at 20:55
Say "goes into" really fast a few times. :-) – Brian Knoblauch Feb 22 '11 at 21:18
AFAIK, gozinta comes from Smalltalk assignment operator, and points in the other direction. I think Squeak, Pharo use := these days. – msandiford May 30 '11 at 2:28

I am currently searching the net for answers to this very question. So far, my favorite is "dart", which I just expounded on over at StackOverflow:

"point" is pretty good too, but I still think I like "dart" better, for its similitude to most languages use of "dot".

:: and => still trip my tounge :/

EDIT only just now, I was reading the other answers again, and I thought about "colon-colon" and how I could shorten it to "co-colon", then "coco" which made me think of "coca-cola" and then "cola", which flows a bit better, but is quite removed. "CoCo" is also a nickname for "Conan O'Brian" so, maybe "Conan" for a quite removed, very brief alias for the "double colon"

share|improve this answer
In reality my upvote here is not for being the correct answer, althought I do really like "dart", but for bringing a huge smile to my face with "CoCo" which happens all too infrequently these days. – Night Owl Mar 21 '13 at 2:45

@umbrella mentioned it earlier, I feel the double colon is probably best pronounced as 'cola'.

I also like 'dart' better than arrow. Of course there are a few kinds which makes it a bit confusing.. Maybe something along these lines: (If leaving out right or left assume right as English is left to right language)

> angle
-> dart 
=> equal/big dart
>> double dart
--> long dart
>>- lawn dart!
share|improve this answer

Not the answer you're looking for? Browse other questions tagged or ask your own question.