How do I check if an element is the last sibling?

For the last cell in a row I want to perform a different action.

This doesn't work:

$('td').each(function(){
    var $this = $(this);
    if ( $this === $this.parent().last('td') )
        {
            alert('123');
        }
})

And neither does it if I remove .parent().

Edit
Report