Buggy code:
public class ApplicationGUI extends JFrame { private String wordsFilename ; private String annoFilename ; private List < String > newWords ; private List < List < String > > newPatterns ; private iSpeller naiveSpeller ; private iSpeller desambSpeller ; private iCorpus corpus ; private Alphabet alphabet ; private XMLGenerator generator ; private PatternFinder pf ; private int currentWordIndex ; public ApplicationGUI ( String wordsFilename , String patternFilename , String corpusFilename ) throws FileNotFoundException , IOException , UnsupportedEncodingException , XMLException { } private void initComponents ( ) { } private void jComboBox1ActionPerformed ( ActionEvent evt ) { } private void jList1ValueChanged ( ListSelectionEvent evt ) { if ( ( this . currentWordIndex ) == ( jList1 . getSelectedIndex ( ) ) ) { return ; } else { if ( ( this . currentWordIndex ) != ( - 1 ) ) { this . saveRecord ( this . currentWordIndex , jTable1 . getSelectedColumns ( ) ) ; } } jComboBox1 . removeAllItems ( ) ; if ( ( jList1 . getSelectedIndex ( ) ) == ( - 1 ) ) { jComboBox1 . setEnabled ( false ) ; jLabel3 . setText ( "" ) ; jTable1 . setModel ( new ApplicationGUI . EmptyModel ( ) ) ; return ; } else { jComboBox1 . setEnabled ( true ) ; } List < SpelledWord > spellings = naiveSpeller . wordSpelling ( ( ( String ) ( jList1 . getSelectedValue ( ) ) ) ) ; List < SpelledWord > selectedSpelling = desambSpeller . wordSpelling ( ( ( String ) ( jList1 . getSelectedValue ( ) ) ) ) ; for ( SpelledWord lv : spellings ) { jComboBox1 . addItem ( lv . getStringAsList ( ) ) ; <START_BUG> if ( lv . toString ( ) . equals ( selectedSpelling . get ( 0 ) . getStringAsList ( ) ) ) { <END_BUG> jComboBox1 . setSelectedItem ( lv . getStringAsList ( ) ) ; } } if ( ( jComboBox1 . getItemCount ( ) ) == 1 ) { jComboBox1 . setEnabled ( false ) ; } if ( ( jComboBox1 . getItemCount ( ) ) == 0 ) { jTable1 . setModel ( new ApplicationGUI . EmptyModel ( ) ) ; return ; } this . currentWordIndex = jList1 . getSelectedIndex ( ) ; } private void jButton1ActionPerformed ( ActionEvent evt ) { } private void jButton2ActionPerformed ( ActionEvent evt ) { } private void jButton3ActionPerformed ( ActionEvent evt ) { } public static void main ( final String [ ] args ) { } private void setPatternParts ( ) { } private void saveRecord ( int idxWord , int [ ] selectedColumns ) { } private class MyTableCellRenderer extends DefaultTableCellRenderer { public Component getTableCellRendererComponent ( JTable table , Object value , boolean isSelected , boolean hasFocus , int row , int column ) { } } private class EmptyModel extends AbstractTableModel { public int getColumnCount ( ) { } public int getRowCount ( ) { } public Object getValueAt ( int row , int col ) { } } private JButton jButton1 ; private JButton jButton2 ; private JButton jButton3 ; private JComboBox jComboBox1 ; private JTextField jFilter ; private JLabel jLabel1 ; private JLabel jLabel3 ; private JList jList1 ; private JScrollPane jScrollPane1 ; private JScrollPane jScrollPane2 ; private JTable jTable1 ; private void saveAnno ( ) { } }

Fix:
if ( lv . getStringAsList ( ) . equals ( selectedSpelling . get ( 0 ) . getStringAsList ( ) ) ) {