Skip to content

Instantly share code, notes, and snippets.

@BenjaminPoulain
Created March 13, 2012 22:18
Show Gist options
  • Save BenjaminPoulain/2032140 to your computer and use it in GitHub Desktop.
Save BenjaminPoulain/2032140 to your computer and use it in GitHub Desktop.
enum KeywordValue {
NotKeyword,
ValidKeyword,
InvalidKeyword
}
static inline KeywordValue parseValidPrimitive(CSSPropertyID id, int value)
{
switch(id) {
case CSSPropertyEmptyCells: // show | hide | inherit
if (id == CSSValueShow
|| id == CSSValueHide)
return ValidKeyword
return InvalidKeyword;
case:
foobar;
}
return NotKeyword;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment