I found a very interesting issue on some platform builds that I would
like to share. See the example below:

...
    case CSSPropertyTextDecoration:
#if ENABLE(CSS3_TEXT_DECORATION)
    case CSSPropertyWebkitTextDecorationLine:
#endif // CSS3_TEXT_DECORATION
        return renderTextDecorationFlagsToCSSValue(style->textDecoration());
...

This breaks build on gtk, win and mac platforms as the precompiler is
unable to understand it as a fall-through case, AFAIK. Proper
implementation would be, then:

...
    case CSSPropertyTextDecoration:
        return renderTextDecorationFlagsToCSSValue(style->textDecoration());
#if ENABLE(CSS3_TEXT_DECORATION)
    case CSSPropertyWebkitTextDecorationLine:
        return renderTextDecorationFlagsToCSSValue(style->textDecoration());
#endif // CSS3_TEXT_DECORATION
...

Where each switch case is handled individually (if you're curious
about it, it is fixed in bug 90493). Said this, I would like to
propose it as a code guideline. As always, inputs and comments are
welcome!

Best regards,

-- 
Bruno de Oliveira Abinader
_______________________________________________
webkit-dev mailing list
webkit-dev@lists.webkit.org
http://lists.webkit.org/mailman/listinfo/webkit-dev

Reply via email to