Commit a3953da5 authored by Chris Fallin's avatar Chris Fallin

Updated based on code-review comments.

parent eb33f9d3
......@@ -88,8 +88,7 @@ static VALUE which_oneof_field(MessageHeader* self, const upb_oneofdef* o) {
fields[upb_fielddef_index(first_field)].case_offset;
uint32_t oneof_case = *((uint32_t*)(Message_data(self) + case_ofs));
// oneof_case == 0 indicates no field set.
if (oneof_case == 0) {
if (oneof_case == ONEOF_CASE_NONE) {
return Qnil;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment