Navigation Menu

Skip to content

Commit

Permalink
Use grn_obj_is_vector_column()
Browse files Browse the repository at this point in the history
  • Loading branch information
kou committed Apr 25, 2017
1 parent 4ea68c5 commit 75fc614
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions ext/groonga/rb-grn-column.c
Expand Up @@ -646,20 +646,12 @@ rb_grn_column_vector_p (VALUE self)
{
grn_ctx *context;
grn_obj *column;
grn_column_flags flags;
grn_column_flags column_type;

rb_grn_column_deconstruct(SELF(self), &column, &context,
NULL, NULL,
NULL, NULL, NULL);

if (column->header.type != GRN_COLUMN_VAR_SIZE) {
return Qfalse;
}

flags = grn_column_get_flags(context, column);
column_type = (flags & GRN_OBJ_COLUMN_TYPE_MASK);
return CBOOL2RVAL(column_type == GRN_OBJ_COLUMN_VECTOR);
return CBOOL2RVAL(grn_obj_is_vector_column(context, column));
}

/*
Expand Down

0 comments on commit 75fc614

Please sign in to comment.