def p_base_type(p):
 if (p[1] == 'bool'):
  p[0] = TType.BOOL
 if (p[1] == 'byte'):
  p[0] = TType.BYTE
 if (p[1] == 'i16'):
  p[0] = TType.I16
 if (p[1] == 'i32'):
  p[0] = TType.I32
 if (p[1] == 'i64'):
  p[0] = TType.I64
 if (p[1] == 'double'):
  p[0] = TType.DOUBLE
 if (p[1] == 'string'):
  p[0] = TType.STRING
 if (p[1] == 'binary'):
  p[0] = TType.BINARY

def p_base_type ( p ) : if ( p [ 1 ] == 'bool' ) : p [ 0 ] = TType . BOOL if ( p [ 1 ] == 'byte' ) : p [ 0 ] = TType . BYTE if ( p [ 1 ] == 'i16' ) : p [ 0 ] = TType . I16 if ( p [ 1 ] == 'i32' ) : p [ 0 ] = TType . I32 if ( p [ 1 ] == 'i64' ) : p [ 0 ] = TType . I64 if ( p [ 1 ] == 'double' ) : p [ 0 ] = TType . DOUBLE if ( p [ 1 ] == 'string' ) : p [ 0 ] = TType . STRING if ( p [ 1 ] == 'binary' ) : p [ 0 ] = TType . BINARY
base_type : bool | byte | i16 | i32 | i64 | double | string | binary .