Buggy code:
public final class TextLayout extends Resource { static class StyleItem { TextStyle style ; int start ; } Font font ; String text ; int ascent ; int descent ; int [ ] segments ; TextLayout . StyleItem [ ] styles ; int layout ; int context ; int attrList ; int [ ] invalidOffsets ; static final char LTR_MARK = '‎' ; static final char RTL_MARK = '‏' ; static final char ZWS = '​' ; static final char ZWNBS = '﻿' ; public TextLayout ( Device device ) { } void checkLayout ( ) { } void computeRuns ( ) { if ( ( attrList ) != 0 ) return ; String segmentsText = getSegmentsText ( ) ; byte [ ] buffer = Converter . wcsToMbcs ( null , segmentsText , false ) ; OS . pango_layout_set_text ( layout , buffer , buffer . length ) ; <START_BUG> if ( ( ( ( ( styles . length ) == 2 ) && ( ( styles [ 0 ] . style ) == null ) ) && ( ( ascent ) == ( - 1 ) ) ) && ( ( descent ) == ( - 1 ) ) ) <END_BUG> return ; int ptr = OS . pango_layout_get_text ( layout ) ; attrList = OS . pango_attr_list_new ( ) ; PangoAttribute attribute = new PangoAttribute ( ) ; char [ ] chars = null ; int segementsLength = segmentsText . length ( ) ; if ( ( ( ( ascent ) != ( - 1 ) ) || ( ( descent ) != ( - 1 ) ) ) && ( segementsLength > 0 ) ) { int iter = OS . pango_layout_get_iter ( layout ) ; if ( iter == 0 ) SWT . error ( ERROR_NO_HANDLES ) ; PangoRectangle rect = new PangoRectangle ( ) ; if ( ( ascent ) != ( - 1 ) ) rect . y = - ( ( ascent ) * ( OS . PANGO_SCALE ) ) ; rect . height = ( ( Math . max ( 0 , ascent ) ) + ( Math . max ( 0 , descent ) ) ) * ( OS . PANGO_SCALE ) ; int lineCount = OS . pango_layout_get_line_count ( layout ) ; chars = new char [ segementsLength + ( lineCount * 2 ) ] ; int oldPos = 0 ; int count = 0 ; do { int bytePos = OS . pango_layout_iter_get_index ( iter ) ; int offset = count * 6 ; int attr = OS . pango_attr_shape_new ( rect , rect ) ; OS . memmove ( attribute , attr , sizeof ) ; attribute . start_index = bytePos + offset ; attribute . end_index = ( bytePos + offset ) + 3 ; OS . memmove ( attr , attribute , sizeof ) ; OS . pango_attr_list_insert ( attrList , attr ) ; attr = OS . pango_attr_shape_new ( rect , rect ) ; OS . memmove ( attribute , attr , sizeof ) ; attribute . start_index = ( bytePos + offset ) + 3 ; attribute . end_index = ( bytePos + offset ) + 6 ; OS . memmove ( attr , attribute , sizeof ) ; OS . pango_attr_list_insert ( attrList , attr ) ; int pos = ( ( int ) ( OS . g_utf8_pointer_to_offset ( ptr , ( ptr + bytePos ) ) ) ) ; chars [ ( pos + ( count * 2 ) ) ] = TextLayout . ZWS ; chars [ ( ( pos + ( count * 2 ) ) + 1 ) ] = TextLayout . ZWNBS ; segmentsText . getChars ( oldPos , pos , chars , ( oldPos + ( count * 2 ) ) ) ; oldPos = pos ; count ++ ; } while ( OS . pango_layout_iter_next_line ( iter ) ) ; OS . pango_layout_iter_free ( iter ) ; segmentsText . getChars ( oldPos , segementsLength , chars , ( oldPos + ( count * 2 ) ) ) ; buffer = Converter . wcsToMbcs ( null , chars , false ) ; OS . pango_layout_set_text ( layout , buffer , buffer . length ) ; ptr = OS . pango_layout_get_text ( layout ) ; } else { chars = new char [ segementsLength ] ; segmentsText . getChars ( 0 , segementsLength , chars , 0 ) ; } int offsetCount = 0 ; for ( int i = 0 ; i < ( chars . length ) ; i ++ ) { char c = chars [ i ] ; if ( ( ( ( c == ( TextLayout . LTR_MARK ) ) || ( c == ( TextLayout . RTL_MARK ) ) ) || ( c == ( TextLayout . ZWNBS ) ) ) || ( c == ( TextLayout . ZWS ) ) ) { offsetCount ++ ; } } invalidOffsets = new int [ offsetCount ] ; offsetCount = 0 ; for ( int i = 0 ; i < ( chars . length ) ; i ++ ) { char c = chars [ i ] ; if ( ( ( ( c == ( TextLayout . LTR_MARK ) ) || ( c == ( TextLayout . RTL_MARK ) ) ) || ( c == ( TextLayout . ZWNBS ) ) ) || ( c == ( TextLayout . ZWS ) ) ) { invalidOffsets [ ( offsetCount ++ ) ] = i ; } } int strlen = OS . strlen ( ptr ) ; for ( int i = 0 ; i < ( ( styles . length ) - 1 ) ; i ++ ) { TextLayout . StyleItem styleItem = styles [ i ] ; TextStyle style = styleItem . style ; if ( style == null ) continue ; int start = translateOffset ( styleItem . start ) ;

Fix:
if ( ( ( ( ( ( styles . length ) == 2 ) && ( ( styles [ 0 ] . style ) == null ) ) && ( ( ascent ) == ( - 1 ) ) ) && ( ( descent ) == ( - 1 ) ) ) && ( ( segments ) == null ) )