The Joel on Software Discussion Group (CLOSED)

A place to discuss Joel on Software. Now closed.

This community works best when people use their real names. Please register for a free account.

Other Groups:
Joel on Software
Business of Software
Design of Software (CLOSED)
.NET Questions (CLOSED)
TechInterview.org
CityDesk
FogBugz
Fog Creek Copilot


The Old Forum


Your hosts:
Albert D. Kallal
Li-Fan Chen
Stephen Jones

IntelliGuess

I would love to get some feedback to a blog I posted recently about the danger of IntelliSense.

http://richardadleta.com/blog/archive/2006/02/21/777.aspx

Thanks.
Richard Adleta Send private email
Wednesday, February 22, 2006
 
 
Place the blame for "Intelliguessing" on the engineers who pick APIs without knowing what they really do, not on the feature itself for allowing them to do it.  The computer can't think for you, so you only have yourself to blame if you don't think either.
Kyle Send private email
Wednesday, February 22, 2006
 
 
Data point:

* I was just testing Mono a little while ago, and it has an IDE which has been improving a lot. I created about 4 different projects, and at least one of them was with GUI (Gtk#). I tried to set the title of the main window by trying to lookup the method with IntelliSense (Autocompletion), and while I tried to find a method with the name "Title" or "SetTitle", I just couldn't find it. Bare in mind that I don't have a lot of experience with Gtk#, though I use Gtk for my programs but use other APIs, including custom ones. I'm not used to AutoCompletion anymore. All I want is great libraries with great orthogonality (consistency) so I don't have to create ugly code nor have to waste time looking things up.

Oh man, I'm definitely going alone against the trend. Actually, not alone, alone, because many people provide me with precious tools, though they aren't visual or definitive per se -- they still need some custom work to keep things consistent and easy.
Lostacular
Wednesday, February 22, 2006
 
 
I agree with Kyle. If the developer is careless enough to use a member without knowing what it does that's their problem. Who would hire such a peron? The interview process should eliminate such careless and unmethodical people.
anony
Wednesday, February 22, 2006
 
 
I don't know. I guess I've never had the problem you describe.

I use IntelliSense to try to find the API I'm looking for when I don't know what it's called, but if I've never used the function, I always check dynamic help for it in VS immediately after selecting it.
Josh McFarlane Send private email
Wednesday, February 22, 2006
 
 
I hope that it didn't seem that I was bashing the feature, but rather just taking on the issues it could (or rather does) create. These issues are legitimate for good as well as bad developers.

To me the more interesting thought about it is how these and other tools are changing both positively and negatively the way that we develop software. I am excited about improving the efficiency of development and look forward to many more new inventions that will become adapted into they way we develop.
Richard Adleta Send private email
Wednesday, February 22, 2006
 
 
I dunno either.  In a somewhat related sense I ran into a similar scenario.

We were investigating the use Win32 threading (CreateThread, BeginThread, etc...) I couldn't remember the function's arguments but I knew the function name, CreateThread.  I typed it in and in a uSec I had the prototype on myscreen.

I couldn't remember which parameter was the one you pass to CreateThread such that it goes to your Thread routine so I went to my bookshelf and pulled a Jeffrey Ricter book down.  The book was a bit dated but figured it was safe since it said WinNT and we support (dwindling support that is) for WinNT clients.

So we implemented our calls using CreateThread.

We later found out that _beginthreadex should be used instead due to a memory leake in the way CreateThread was being used.  (I forget all the details of the merits of this) but this was a case where my documentation was out of date and the new IDE was of no help.

I wonder if this post is going off on a tangent but my point is: know your framework -- I think Kyle stated this -- I'm just more 'round about ;)
Eric (another ISV guy with his company)
Wednesday, February 22, 2006
 
 
I use Qt (trolltech.com) at work. Intellisense works wonderfully with it. Of course, part of the credit goes to the super intuitive api that Qt has. And yes, it does increase my productivity quite a bit.
TryGuessingThisOne
Wednesday, February 22, 2006
 
 
Can you give some examples of cases where you're 1, 2, and 3 would occur?
Phil Send private email
Wednesday, February 22, 2006
 
 
The only time I use IntelliGuess is in VB, and I use it in that instance because I often consume several ActiveX objects and I find it easier to poke around than to memorize every method and property name.

Normally, the first thing I do when I install a new C++ or Java IDE is to disable IntelliGuess. You would be surprised how snappy the IDE becomes when all that BS is disabled.

OT: the _beginthreadex vs. CreateThread problem has been around for 10 years. The problem with CreateThread is it does not property initialize the C run-time library, which means if you use any of the standard C functions in stdio.h, dir.h, etc., you can have problems.
MBJ Send private email
Wednesday, February 22, 2006
 
 
MBJ,

Yes, it was a while ago.  When Win2K was coming out I was *finally* getting bits of our product into threads and I was running into documentation on this outside my book and my IDE was of no help.

I'm not familiar with this product in question, Intellisense, but from the OP I was more/less agreeing with the OP and to Kyle.

Interesting topic! (sorry for the hijack and thanks!)
Eric (another ISV guy with his company)
Wednesday, February 22, 2006
 
 
Phil, I took a stab at it and added examples to the blog as requested.

http://richardadleta.com/blog/archive/2006/02/21/777.aspx

I hope they help.
Richard Adleta Send private email
Wednesday, February 22, 2006
 
 
> We later found out that _beginthreadex should be used
> instead due to a memory leake in the way CreateThread
> was being used.

The CreateThread works just fine if you remember to call CloseHandle to release the memory. In fact my guess is _beginthreadex actually CreateThread.

> this was a case where my documentation was out of date

I suspect the documentation was not so much out of date but rather, just lacking. The Borland Win32 SDK help file:

  http://www.zeusedit.com/forum/viewtopic.php?t=7

is as old as the hills and it even makes reference to this point:

  CreateThread Return Value
  If the function succeeds, the return value is a
  handle to the new thread.

  The thread object remains in the system until the
  thread has terminated and all handles to it have
  been closed through a call to CloseHandle.
Jussi Jumppanen
Thursday, February 23, 2006
 
 
MBJ Send private email
Thursday, February 23, 2006
 
 
This MSDN page you refer to contains the same pretty much the same information as found in the Borland Win32 help file, but naturally it also contains some recent additions.

> _beginthreadex vs. CreateThread problem has been
> around for 10 years

I prefer to use the CreateThread API and for me it seems to work just fine ;)
Jussi Jumppanen
Thursday, February 23, 2006
 
 

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics
 
Powered by FogBugz