lastRow question


lastRow does not have a pointer in front of it, despite not being referenced anywhere else in the Homepwner project…yet it still works. Why is that?

[code]- (IBAction)addNewItem:(id)sender
// Create a new BNRItem and add it to the store
BNRItem *newItem = [[BNRItemStore sharedStore] createItem];

// Figure out where that item is in the array
NSInteger lastRow = [[[BNRItemStore sharedStore]allItems] indexOfObject:newItem];

// Make a new index path for the 0th section, last row
NSIndexPath *indexPath = [NSIndexPath indexPathForRow:lastRow inSection:0];

// Insert this new row into the table.
[self.tableView insertRowsAtIndexPaths:@[indexPath]



Upon Googling my question, I found the answer.