Looking at Apple's ToolbarSearch example, I see that their view controller's searchBar variable has a retain property and it does this:
searchBar = [[UISearchBar alloc] initWithFrame:CGRectMake(0.0, 0.0, 400.0, 0.0)];
in the controller's dealloc, the searchBar is released. However, its viewDidUnload doesn't release but just sets the searchBar variable to nil.
I thought the alloc increments the retain count and that the retain property of the variable additionally increments the count. If this is true, wouldn't it mean the searchBar needs to be released in viewDidUnload?