Hacker News new | past | comments | ask | show | jobs | submit login

Autocomplete/parameter help isn't about "hey, look fewer keystrokes!". It's about context-aware lookup of what you need, and avoiding stupid mistaks (reordering parameters, typos in method names).

The time it takes to write a the first few characters of a method name and then hit the completion key is a tiny amount smaller than just typing the method name outright. But that isn't the point: if I didn't have autocomplete, I'd alt+tab to a browser with class documentation or start searching in the code for a previous invocation of a method with that name I only vaguely remember.

With autocomplete, I don't have to remember variable/property/method names, I can either list them or see a list that begins if I just remember a prefix. This is less unnecessary state in my head and thus more time to think about the actual problem.

It's an absolutely enormous difference in time spent, and considering the time it takes to context switch back to where you were, I'd say it saves me hours every day.




This. Autocomplete is like GPS for writing code in the presence of large libraries and complex APIs. It has nothing to do (at least now) with saving on keystrokes, and intellisense marketing docs post 1997 exclude this as a selling point.


The flip side is that by lowering the cognitive burden it breaks the feedback loop nudging programmers to create simple/elegant apis. I suspect we would be seeing fewer complex api's if there was less of a reliance on IDE's.


I'm not sure. You can look at dynamic language libraries and see similar increases in complexity (batteries included began with python), while they cannot benefit from code completion very much given a lack of static type info. The increase in library complexity is probably more related to demands on what we need to write where tooling is just a supporter.


Java and Python are good languages to compare here since Java appears to have the most money thrown at IDE's in the recent past. Python has a few IDE's but theyre nowhere as magical as Java based IDE's. The average python api that I have come across is usually much more concise than its Java equivalent and there is a strong culture of dwim in the Python community. How much of this is a result of the tooling support for either language and how much is a cultural artifact of the respective community is an open question.


That is a great analogy.


On the other hand, typing 3-4 characters is faster than typing 20. Also, I think there is a kind of reverse "hey, look fewer keystrokes!" effect, though. When you have autocomplete, there is no excuse to not use long, descriptive names for everything. I think that style would be a lot harder to sell if it was not for autocomplete.


This.

The text editor people don't seem to get it but _not_ spending significant amounts of time each day looking up method names / parameters does add up.

The other reason is because.

It annoys the shit out of me when something that could be automated isn't.


> I can either list them or see a list that begins if I just remember a prefix.

I think there is a deeper issue if identifiers are becoming so long that it's hard to remember them. But working with someone else's code is one of the few times I've found autocomplete to be useful, largely because it helps with getting around these issues.


Most of the code you have to call is probably part of a library/platform/runtime (e.g. jre, .net, boost, c standard lib). Even in small libraries it is difficult to learn all the type/method names by heart, and before you have used a function the first time, you have to discover/learn it somehow.

Identifiers (e.g. class or method names) don't have to be particularly long before you can screw up something silly like how to CamelCase it, or accidentally swap the order of a 2-argument method.

When I have reasonable domain knowledge, like say I include a vector math library, I can guess the type and method names and use the lib through autocomplete without ever looking at documentation.


And with IntelliJ IDEA you do not even have to remember the prefix. A substring is often enough.


Ditto visual studio intellisense and I bet eclipse JDT code completion.




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

Search: