Commit 4f1e4aa2 authored by Eugene Kosov's avatar Eugene Kosov

fix clang warnings

parent 26c389b7
...@@ -1317,7 +1317,7 @@ char *ha_connect::GetRealString(PCSZ s) ...@@ -1317,7 +1317,7 @@ char *ha_connect::GetRealString(PCSZ s)
{ {
char *sv; char *sv;
if (IsPartitioned() && s && partname && *partname) { if (IsPartitioned() && s && *partname) {
sv= (char*)PlugSubAlloc(xp->g, NULL, 0); sv= (char*)PlugSubAlloc(xp->g, NULL, 0);
sprintf(sv, s, partname); sprintf(sv, s, partname);
PlugSubAlloc(xp->g, NULL, strlen(sv) + 1); PlugSubAlloc(xp->g, NULL, strlen(sv) + 1);
......
...@@ -407,11 +407,11 @@ public: ...@@ -407,11 +407,11 @@ public:
ha_mroonga(handlerton *hton, TABLE_SHARE *share_arg); ha_mroonga(handlerton *hton, TABLE_SHARE *share_arg);
~ha_mroonga(); ~ha_mroonga();
const char *table_type() const; // required const char *table_type() const; // required
const char *index_type(uint inx); const char *index_type(uint inx) mrn_override;
const char **bas_ext() const; // required const char **bas_ext() const; // required
ulonglong table_flags() const; // required ulonglong table_flags() const mrn_override; // required
ulong index_flags(uint idx, uint part, bool all_parts) const; // required ulong index_flags(uint idx, uint part, bool all_parts) const mrn_override; // required
// required // required
int create(const char *name, TABLE *form, HA_CREATE_INFO *info int create(const char *name, TABLE *form, HA_CREATE_INFO *info
...@@ -430,40 +430,40 @@ public: ...@@ -430,40 +430,40 @@ public:
#ifndef MRN_HANDLER_HAVE_HA_CLOSE #ifndef MRN_HANDLER_HAVE_HA_CLOSE
int close(); // required int close(); // required
#endif #endif
int info(uint flag); // required int info(uint flag) mrn_override; // required
uint lock_count() const; uint lock_count() const mrn_override;
THR_LOCK_DATA **store_lock(THD *thd, // required THR_LOCK_DATA **store_lock(THD *thd, // required
THR_LOCK_DATA **to, THR_LOCK_DATA **to,
enum thr_lock_type lock_type); enum thr_lock_type lock_type) mrn_override;
int external_lock(THD *thd, int lock_type); int external_lock(THD *thd, int lock_type) mrn_override;
int rnd_init(bool scan); // required int rnd_init(bool scan) mrn_override; // required
int rnd_end(); int rnd_end() mrn_override;
#ifndef MRN_HANDLER_HAVE_HA_RND_NEXT #ifndef MRN_HANDLER_HAVE_HA_RND_NEXT
int rnd_next(uchar *buf); // required int rnd_next(uchar *buf); // required
#endif #endif
#ifndef MRN_HANDLER_HAVE_HA_RND_POS #ifndef MRN_HANDLER_HAVE_HA_RND_POS
int rnd_pos(uchar *buf, uchar *pos); // required int rnd_pos(uchar *buf, uchar *pos); // required
#endif #endif
void position(const uchar *record); // required void position(const uchar *record) mrn_override; // required
int extra(enum ha_extra_function operation); int extra(enum ha_extra_function operation) mrn_override;
int extra_opt(enum ha_extra_function operation, ulong cache_size); int extra_opt(enum ha_extra_function operation, ulong cache_size) mrn_override;
int delete_table(const char *name); int delete_table(const char *name) mrn_override;
int write_row(uchar *buf); int write_row(uchar *buf) mrn_override;
int update_row(const uchar *old_data, uchar *new_data); int update_row(const uchar *old_data, uchar *new_data) mrn_override;
int delete_row(const uchar *buf); int delete_row(const uchar *buf) mrn_override;
uint max_supported_record_length() const; uint max_supported_record_length() const mrn_override;
uint max_supported_keys() const; uint max_supported_keys() const mrn_override;
uint max_supported_key_parts() const; uint max_supported_key_parts() const mrn_override;
uint max_supported_key_length() const; uint max_supported_key_length() const mrn_override;
uint max_supported_key_part_length() const; uint max_supported_key_part_length() const mrn_override;
ha_rows records_in_range(uint inx, key_range *min_key, key_range *max_key); ha_rows records_in_range(uint inx, key_range *min_key, key_range *max_key) mrn_override;
int index_init(uint idx, bool sorted); int index_init(uint idx, bool sorted) mrn_override;
int index_end(); int index_end() mrn_override;
#ifndef MRN_HANDLER_HAVE_HA_INDEX_READ_MAP #ifndef MRN_HANDLER_HAVE_HA_INDEX_READ_MAP
int index_read_map(uchar * buf, const uchar * key, int index_read_map(uchar * buf, const uchar * key,
key_part_map keypart_map, key_part_map keypart_map,
...@@ -485,35 +485,35 @@ public: ...@@ -485,35 +485,35 @@ public:
#ifndef MRN_HANDLER_HAVE_HA_INDEX_LAST #ifndef MRN_HANDLER_HAVE_HA_INDEX_LAST
int index_last(uchar *buf); int index_last(uchar *buf);
#endif #endif
int index_next_same(uchar *buf, const uchar *key, uint keylen); int index_next_same(uchar *buf, const uchar *key, uint keylen) mrn_override;
int ft_init(); int ft_init() mrn_override;
FT_INFO *ft_init_ext(uint flags, uint inx, String *key); FT_INFO *ft_init_ext(uint flags, uint inx, String *key) mrn_override;
int ft_read(uchar *buf); int ft_read(uchar *buf) mrn_override;
const Item *cond_push(const Item *cond); const Item *cond_push(const Item *cond) mrn_override;
void cond_pop(); void cond_pop() mrn_override;
bool get_error_message(int error, String *buf); bool get_error_message(int error, String *buf) mrn_override;
int reset(); int reset() mrn_override;
handler *clone(const char *name, MEM_ROOT *mem_root); handler *clone(const char *name, MEM_ROOT *mem_root) mrn_override;
uint8 table_cache_type(); uint8 table_cache_type() mrn_override;
#ifdef MRN_HANDLER_HAVE_MULTI_RANGE_READ #ifdef MRN_HANDLER_HAVE_MULTI_RANGE_READ
ha_rows multi_range_read_info_const(uint keyno, RANGE_SEQ_IF *seq, ha_rows multi_range_read_info_const(uint keyno, RANGE_SEQ_IF *seq,
void *seq_init_param, void *seq_init_param,
uint n_ranges, uint *bufsz, uint n_ranges, uint *bufsz,
uint *flags, Cost_estimate *cost); uint *flags, Cost_estimate *cost) mrn_override;
ha_rows multi_range_read_info(uint keyno, uint n_ranges, uint keys, ha_rows multi_range_read_info(uint keyno, uint n_ranges, uint keys,
#ifdef MRN_HANDLER_HAVE_MULTI_RANGE_READ_INFO_KEY_PARTS #ifdef MRN_HANDLER_HAVE_MULTI_RANGE_READ_INFO_KEY_PARTS
uint key_parts, uint key_parts,
#endif #endif
uint *bufsz, uint *flags, Cost_estimate *cost); uint *bufsz, uint *flags, Cost_estimate *cost) mrn_override;
int multi_range_read_init(RANGE_SEQ_IF *seq, void *seq_init_param, int multi_range_read_init(RANGE_SEQ_IF *seq, void *seq_init_param,
uint n_ranges, uint mode, uint n_ranges, uint mode,
HANDLER_BUFFER *buf); HANDLER_BUFFER *buf) mrn_override;
int multi_range_read_next(range_id_t *range_info); int multi_range_read_next(range_id_t *range_info) mrn_override;
#else // MRN_HANDLER_HAVE_MULTI_RANGE_READ #else // MRN_HANDLER_HAVE_MULTI_RANGE_READ
int read_multi_range_first(KEY_MULTI_RANGE **found_range_p, int read_multi_range_first(KEY_MULTI_RANGE **found_range_p,
KEY_MULTI_RANGE *ranges, KEY_MULTI_RANGE *ranges,
...@@ -523,38 +523,38 @@ public: ...@@ -523,38 +523,38 @@ public:
int read_multi_range_next(KEY_MULTI_RANGE **found_range_p); int read_multi_range_next(KEY_MULTI_RANGE **found_range_p);
#endif // MRN_HANDLER_HAVE_MULTI_RANGE_READ #endif // MRN_HANDLER_HAVE_MULTI_RANGE_READ
#ifdef MRN_HANDLER_START_BULK_INSERT_HAS_FLAGS #ifdef MRN_HANDLER_START_BULK_INSERT_HAS_FLAGS
void start_bulk_insert(ha_rows rows, uint flags); void start_bulk_insert(ha_rows rows, uint flags) mrn_override;
#else #else
void start_bulk_insert(ha_rows rows); void start_bulk_insert(ha_rows rows);
#endif #endif
int end_bulk_insert(); int end_bulk_insert() mrn_override;
int delete_all_rows(); int delete_all_rows() mrn_override;
int truncate(); int truncate() mrn_override;
double scan_time(); double scan_time() mrn_override;
double read_time(uint index, uint ranges, ha_rows rows); double read_time(uint index, uint ranges, ha_rows rows) mrn_override;
#ifdef MRN_HANDLER_HAVE_KEYS_TO_USE_FOR_SCANNING #ifdef MRN_HANDLER_HAVE_KEYS_TO_USE_FOR_SCANNING
const key_map *keys_to_use_for_scanning(); const key_map *keys_to_use_for_scanning() mrn_override;
#endif #endif
ha_rows estimate_rows_upper_bound(); ha_rows estimate_rows_upper_bound() mrn_override;
void update_create_info(HA_CREATE_INFO* create_info); void update_create_info(HA_CREATE_INFO* create_info) mrn_override;
int rename_table(const char *from, const char *to); int rename_table(const char *from, const char *to) mrn_override;
bool is_crashed() const; bool is_crashed() const mrn_override;
bool auto_repair(int error) const; bool auto_repair(int error) const mrn_override;
bool auto_repair() const; bool auto_repair() const;
int disable_indexes(uint mode); int disable_indexes(uint mode) mrn_override;
int enable_indexes(uint mode); int enable_indexes(uint mode) mrn_override;
int check(THD* thd, HA_CHECK_OPT* check_opt); int check(THD* thd, HA_CHECK_OPT* check_opt) mrn_override;
int repair(THD* thd, HA_CHECK_OPT* check_opt); int repair(THD* thd, HA_CHECK_OPT* check_opt) mrn_override;
bool check_and_repair(THD *thd); bool check_and_repair(THD *thd) mrn_override;
int analyze(THD* thd, HA_CHECK_OPT* check_opt); int analyze(THD* thd, HA_CHECK_OPT* check_opt) mrn_override;
int optimize(THD* thd, HA_CHECK_OPT* check_opt); int optimize(THD* thd, HA_CHECK_OPT* check_opt) mrn_override;
bool is_fatal_error(int error_num, uint flags=0); bool is_fatal_error(int error_num, uint flags=0) mrn_override;
bool check_if_incompatible_data(HA_CREATE_INFO *create_info, bool check_if_incompatible_data(HA_CREATE_INFO *create_info,
uint table_changes); uint table_changes) mrn_override;
#ifdef MRN_HANDLER_HAVE_CHECK_IF_SUPPORTED_INPLACE_ALTER #ifdef MRN_HANDLER_HAVE_CHECK_IF_SUPPORTED_INPLACE_ALTER
enum_alter_inplace_result enum_alter_inplace_result
check_if_supported_inplace_alter(TABLE *altered_table, check_if_supported_inplace_alter(TABLE *altered_table,
Alter_inplace_info *ha_alter_info); Alter_inplace_info *ha_alter_info) mrn_override;
#else #else
uint alter_table_flags(uint flags); uint alter_table_flags(uint flags);
# ifdef MRN_HANDLER_HAVE_FINAL_ADD_INDEX # ifdef MRN_HANDLER_HAVE_FINAL_ADD_INDEX
...@@ -570,78 +570,78 @@ public: ...@@ -570,78 +570,78 @@ public:
int update_auto_increment(); int update_auto_increment();
void set_next_insert_id(ulonglong id); void set_next_insert_id(ulonglong id);
void get_auto_increment(ulonglong offset, ulonglong increment, ulonglong nb_desired_values, void get_auto_increment(ulonglong offset, ulonglong increment, ulonglong nb_desired_values,
ulonglong *first_value, ulonglong *nb_reserved_values); ulonglong *first_value, ulonglong *nb_reserved_values) mrn_override;
void restore_auto_increment(ulonglong prev_insert_id); void restore_auto_increment(ulonglong prev_insert_id);
void release_auto_increment(); void release_auto_increment() mrn_override;
int check_for_upgrade(HA_CHECK_OPT *check_opt); int check_for_upgrade(HA_CHECK_OPT *check_opt) mrn_override;
#ifdef MRN_HANDLER_HAVE_RESET_AUTO_INCREMENT #ifdef MRN_HANDLER_HAVE_RESET_AUTO_INCREMENT
int reset_auto_increment(ulonglong value); int reset_auto_increment(ulonglong value) mrn_override;
#endif #endif
bool was_semi_consistent_read(); bool was_semi_consistent_read() mrn_override;
void try_semi_consistent_read(bool yes); void try_semi_consistent_read(bool yes) mrn_override;
void unlock_row(); void unlock_row() mrn_override;
int start_stmt(THD *thd, thr_lock_type lock_type); int start_stmt(THD *thd, thr_lock_type lock_type) mrn_override;
protected: protected:
#ifdef MRN_HANDLER_RECORDS_RETURN_ERROR #ifdef MRN_HANDLER_RECORDS_RETURN_ERROR
int records(ha_rows *num_rows); int records(ha_rows *num_rows);
#else #else
ha_rows records(); ha_rows records() mrn_override;
#endif #endif
#ifdef MRN_HANDLER_HAVE_HA_RND_NEXT #ifdef MRN_HANDLER_HAVE_HA_RND_NEXT
int rnd_next(uchar *buf); int rnd_next(uchar *buf) mrn_override;
#endif #endif
#ifdef MRN_HANDLER_HAVE_HA_RND_POS #ifdef MRN_HANDLER_HAVE_HA_RND_POS
int rnd_pos(uchar *buf, uchar *pos); int rnd_pos(uchar *buf, uchar *pos) mrn_override;
#endif #endif
#ifdef MRN_HANDLER_HAVE_HA_INDEX_READ_MAP #ifdef MRN_HANDLER_HAVE_HA_INDEX_READ_MAP
int index_read_map(uchar *buf, const uchar *key, int index_read_map(uchar *buf, const uchar *key,
key_part_map keypart_map, key_part_map keypart_map,
enum ha_rkey_function find_flag); enum ha_rkey_function find_flag) mrn_override;
#endif #endif
#ifdef MRN_HANDLER_HAVE_HA_INDEX_NEXT #ifdef MRN_HANDLER_HAVE_HA_INDEX_NEXT
int index_next(uchar *buf); int index_next(uchar *buf) mrn_override;
#endif #endif
#ifdef MRN_HANDLER_HAVE_HA_INDEX_PREV #ifdef MRN_HANDLER_HAVE_HA_INDEX_PREV
int index_prev(uchar *buf); int index_prev(uchar *buf) mrn_override;
#endif #endif
#ifdef MRN_HANDLER_HAVE_HA_INDEX_FIRST #ifdef MRN_HANDLER_HAVE_HA_INDEX_FIRST
int index_first(uchar *buf); int index_first(uchar *buf) mrn_override;
#endif #endif
#ifdef MRN_HANDLER_HAVE_HA_INDEX_LAST #ifdef MRN_HANDLER_HAVE_HA_INDEX_LAST
int index_last(uchar *buf); int index_last(uchar *buf) mrn_override;
#endif #endif
void change_table_ptr(TABLE *table_arg, TABLE_SHARE *share_arg); void change_table_ptr(TABLE *table_arg, TABLE_SHARE *share_arg) mrn_override;
bool primary_key_is_clustered(); bool primary_key_is_clustered() mrn_override;
bool is_fk_defined_on_table_or_index(uint index); bool is_fk_defined_on_table_or_index(uint index) mrn_override;
char *get_foreign_key_create_info(); char *get_foreign_key_create_info() mrn_override;
#ifdef MRN_HANDLER_HAVE_GET_TABLESPACE_NAME #ifdef MRN_HANDLER_HAVE_GET_TABLESPACE_NAME
char *get_tablespace_name(THD *thd, char *name, uint name_len); char *get_tablespace_name(THD *thd, char *name, uint name_len);
#endif #endif
bool can_switch_engines(); bool can_switch_engines() mrn_override;
int get_foreign_key_list(THD *thd, List<FOREIGN_KEY_INFO> *f_key_list); int get_foreign_key_list(THD *thd, List<FOREIGN_KEY_INFO> *f_key_list) mrn_override;
int get_parent_foreign_key_list(THD *thd, List<FOREIGN_KEY_INFO> *f_key_list); int get_parent_foreign_key_list(THD *thd, List<FOREIGN_KEY_INFO> *f_key_list) mrn_override;
uint referenced_by_foreign_key(); uint referenced_by_foreign_key() mrn_override;
void init_table_handle_for_HANDLER(); void init_table_handle_for_HANDLER() mrn_override;
void free_foreign_key_create_info(char* str); void free_foreign_key_create_info(char* str) mrn_override;
#ifdef MRN_HAVE_HA_REBIND_PSI #ifdef MRN_HAVE_HA_REBIND_PSI
void unbind_psi(); void unbind_psi() mrn_override;
void rebind_psi(); void rebind_psi() mrn_override;
#endif #endif
my_bool register_query_cache_table(THD *thd, my_bool register_query_cache_table(THD *thd,
char *table_key, char *table_key,
uint key_length, uint key_length,
qc_engine_callback *engine_callback, qc_engine_callback *engine_callback,
ulonglong *engine_data); ulonglong *engine_data) mrn_override;
#ifdef MRN_HANDLER_HAVE_CHECK_IF_SUPPORTED_INPLACE_ALTER #ifdef MRN_HANDLER_HAVE_CHECK_IF_SUPPORTED_INPLACE_ALTER
bool prepare_inplace_alter_table(TABLE *altered_table, bool prepare_inplace_alter_table(TABLE *altered_table,
Alter_inplace_info *ha_alter_info); Alter_inplace_info *ha_alter_info) mrn_override;
bool inplace_alter_table(TABLE *altered_table, bool inplace_alter_table(TABLE *altered_table,
Alter_inplace_info *ha_alter_info); Alter_inplace_info *ha_alter_info) mrn_override;
bool commit_inplace_alter_table(TABLE *altered_table, bool commit_inplace_alter_table(TABLE *altered_table,
Alter_inplace_info *ha_alter_info, Alter_inplace_info *ha_alter_info,
bool commit); bool commit) mrn_override;
void notify_table_changed(); void notify_table_changed() mrn_override;
#endif #endif
private: private:
...@@ -692,7 +692,7 @@ private: ...@@ -692,7 +692,7 @@ private:
int generic_geo_open_cursor(const uchar *key, enum ha_rkey_function find_flag); int generic_geo_open_cursor(const uchar *key, enum ha_rkey_function find_flag);
#ifdef MRN_HANDLER_HAVE_HA_CLOSE #ifdef MRN_HANDLER_HAVE_HA_CLOSE
int close(); int close() mrn_override;
#endif #endif
bool is_dry_write(); bool is_dry_write();
bool is_enable_optimization(); bool is_enable_optimization();
......
...@@ -89,12 +89,6 @@ grn_tiny_array_at_inline(grn_tiny_array *array, grn_id id) ...@@ -89,12 +89,6 @@ grn_tiny_array_at_inline(grn_tiny_array *array, grn_id id)
return id ? grn_tiny_array_put(array, id) : NULL; return id ? grn_tiny_array_put(array, id) : NULL;
} }
inline static void *
grn_tiny_array_next(grn_tiny_array *array)
{
return grn_tiny_array_put(array, array->max + 1);
}
void void
grn_tiny_array_init(grn_ctx *ctx, grn_tiny_array *array, grn_tiny_array_init(grn_ctx *ctx, grn_tiny_array *array,
uint16_t element_size, uint16_t flags) uint16_t element_size, uint16_t flags)
...@@ -202,15 +196,6 @@ grn_tiny_bitmap_put_byte(grn_tiny_bitmap *bitmap, grn_id bit_id) { ...@@ -202,15 +196,6 @@ grn_tiny_bitmap_put_byte(grn_tiny_bitmap *bitmap, grn_id bit_id) {
return (uint8_t *)*block + byte_id - offset; return (uint8_t *)*block + byte_id - offset;
} }
/* Requirements: bit_id != GRN_ID_NIL. */
/* Return value: 1/0 on success, -1 on failure. */
inline static int
grn_tiny_bitmap_get(grn_tiny_bitmap *bitmap, grn_id bit_id)
{
uint8_t * const ptr = grn_tiny_bitmap_get_byte(bitmap, bit_id);
return ptr ? ((*ptr >> (bit_id & 7)) & 1) : -1;
}
/* Requirements: bit_id != GRN_ID_NIL. */ /* Requirements: bit_id != GRN_ID_NIL. */
/* Return value: 1/0 on success, -1 on failure. */ /* Return value: 1/0 on success, -1 on failure. */
/* Note: A bitmap is extended if needed. */ /* Note: A bitmap is extended if needed. */
...@@ -309,18 +294,6 @@ grn_io_array_bit_off(grn_ctx *ctx, grn_io *io, ...@@ -309,18 +294,6 @@ grn_io_array_bit_off(grn_ctx *ctx, grn_io *io,
return ptr; return ptr;
} }
inline static void *
grn_io_array_bit_flip(grn_ctx *ctx, grn_io *io,
uint32_t segment_id, uint32_t offset)
{
uint8_t * const ptr = (uint8_t *)grn_io_array_at_inline(
ctx, io, segment_id, (offset >> 3) + 1, GRN_TABLE_ADD);
if (ptr) {
*ptr ^= 1 << (offset & 7);
}
return ptr;
}
/* grn_table_queue */ /* grn_table_queue */
static void static void
...@@ -1738,13 +1711,6 @@ get_value(grn_ctx *ctx, grn_hash *hash, entry_str *n) ...@@ -1738,13 +1711,6 @@ get_value(grn_ctx *ctx, grn_hash *hash, entry_str *n)
return grn_hash_entry_get_value(ctx, hash, (grn_hash_entry *)n); return grn_hash_entry_get_value(ctx, hash, (grn_hash_entry *)n);
} }
inline static grn_rc
put_key(grn_ctx *ctx, grn_hash *hash, entry_str *n, uint32_t h,
const char *key, unsigned int len)
{
return grn_hash_entry_put_key(ctx, hash, (grn_hash_entry *)n, h, key, len);
}
inline static int inline static int
match_key(grn_ctx *ctx, grn_hash *hash, entry_str *ee, uint32_t h, match_key(grn_ctx *ctx, grn_hash *hash, entry_str *ee, uint32_t h,
const char *key, unsigned int len) const char *key, unsigned int len)
......
...@@ -2194,23 +2194,6 @@ buffer_close(grn_ctx *ctx, grn_ii *ii, uint32_t pseg) ...@@ -2194,23 +2194,6 @@ buffer_close(grn_ctx *ctx, grn_ii *ii, uint32_t pseg)
return GRN_SUCCESS; return GRN_SUCCESS;
} }
inline static uint32_t
buffer_open_if_capable(grn_ctx *ctx, grn_ii *ii, int32_t seg, int size, buffer **b)
{
uint32_t pseg, pos = SEG2POS(seg, 0);
if ((pseg = buffer_open(ctx, ii, pos, NULL, b)) != GRN_II_PSEG_NOT_ASSIGNED) {
uint16_t nterms = (*b)->header.nterms - (*b)->header.nterms_void;
if (!((nterms < 4096 ||
(ii->header->total_chunk_size >> ((nterms >> 8) - 6))
> (*b)->header.chunk_size) &&
((*b)->header.buffer_free >= size + sizeof(buffer_term)))) {
buffer_close(ctx, ii, pseg);
return GRN_II_PSEG_NOT_ASSIGNED;
}
}
return pseg;
}
typedef struct { typedef struct {
uint32_t rid; uint32_t rid;
uint32_t sid; uint32_t sid;
......
...@@ -142,20 +142,6 @@ pat_get(grn_ctx *ctx, grn_pat *pat, grn_id id) ...@@ -142,20 +142,6 @@ pat_get(grn_ctx *ctx, grn_pat *pat, grn_id id)
return res; return res;
} }
inline static pat_node *
pat_node_new(grn_ctx *ctx, grn_pat *pat, grn_id *id)
{
uint32_t n = pat->header->curr_rec + 1;
pat_node *res;
if (n > GRN_ID_MAX) { return NULL; }
if ((res = pat_get(ctx, pat, n))) {
pat->header->curr_rec = n;
pat->header->n_entries++;
}
if (id) { *id = n; }
return res;
}
/* sis operation */ /* sis operation */
inline static sis_node * inline static sis_node *
......
...@@ -187,55 +187,6 @@ grn_ts_ref_zero(void) ...@@ -187,55 +187,6 @@ grn_ts_ref_zero(void)
return (grn_ts_ref){ 0, 0.0 }; return (grn_ts_ref){ 0, 0.0 };
} }
/* grn_ts_bool_vector_zero() returns a zero. */
inline static grn_ts_bool_vector
grn_ts_bool_vector_zero(void)
{
return (grn_ts_bool_vector){ NULL, 0 };
}
/* grn_ts_int_vector_zero() returns a zero. */
inline static grn_ts_int_vector
grn_ts_int_vector_zero(void)
{
return (grn_ts_int_vector){ NULL, 0 };
}
/* grn_ts_float_vector_zero() returns a zero. */
inline static grn_ts_float_vector
grn_ts_float_vector_zero(void)
{
return (grn_ts_float_vector){ NULL, 0 };
}
/* grn_ts_time_vector_zero() returns a zero. */
inline static grn_ts_time_vector
grn_ts_time_vector_zero(void)
{
return (grn_ts_time_vector){ NULL, 0 };
}
/* grn_ts_text_vector_zero() returns a zero. */
inline static grn_ts_text_vector
grn_ts_text_vector_zero(void)
{
return (grn_ts_text_vector){ NULL, 0 };
}
/* grn_ts_geo_vector_zero() returns a zero. */
inline static grn_ts_geo_vector
grn_ts_geo_vector_zero(void)
{
return (grn_ts_geo_vector){ NULL, 0 };
}
/* grn_ts_ref_vector_zero() returns a zero. */
inline static grn_ts_ref_vector
grn_ts_ref_vector_zero(void)
{
return (grn_ts_ref_vector){ NULL, 0 };
}
/* grn_ts_data_type_to_kind() returns a kind associated with a type. */ /* grn_ts_data_type_to_kind() returns a kind associated with a type. */
static grn_ts_data_kind static grn_ts_data_kind
grn_ts_data_type_to_kind(grn_ts_data_type type) grn_ts_data_type_to_kind(grn_ts_data_type type)
......
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