MySQL 8.4.0
Source Code Documentation
my_compare.cc File Reference
#include <sys/types.h>
#include <algorithm>
#include "my_base.h"
#include "my_byteorder.h"
#include "my_compare.h"
#include "my_inttypes.h"
#include "my_macros.h"
#include "myisampack.h"
#include "mysql/strings/m_ctype.h"

Macros

#define CMP_NUM(a, b)   (((a) < (b)) ? -1 : ((a) == (b)) ? 0 : 1)
 
#define FCMP(A, B)   ((int)(A) - (int)(B))
 

Functions

int ha_compare_text (const CHARSET_INFO *charset_info, const uchar *a, uint a_length, const uchar *b, uint b_length, bool part_key)
 
static int compare_bin (const uchar *a, uint a_length, const uchar *b, uint b_length, bool part_key, bool skip_end_space)
 
int ha_key_cmp (const HA_KEYSEG *keyseg, const uchar *a, const uchar *b, uint key_length, uint nextflag, uint *diff_pos)
 

Macro Definition Documentation

◆ CMP_NUM

#define CMP_NUM (   a,
 
)    (((a) < (b)) ? -1 : ((a) == (b)) ? 0 : 1)

◆ FCMP

#define FCMP (   A,
 
)    ((int)(A) - (int)(B))

Function Documentation

◆ compare_bin()

static int compare_bin ( const uchar a,
uint  a_length,
const uchar b,
uint  b_length,
bool  part_key,
bool  skip_end_space 
)
static

◆ ha_compare_text()

int ha_compare_text ( const CHARSET_INFO charset_info,
const uchar a,
uint  a_length,
const uchar b,
uint  b_length,
bool  part_key 
)

◆ ha_key_cmp()

int ha_key_cmp ( const HA_KEYSEG keyseg,
const uchar a,
const uchar b,
uint  key_length,
uint  nextflag,
uint *  diff_pos 
)