summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2016-04-01 18:42:15 +0200
committerSergei Golubchik <serg@mariadb.org>2016-04-01 22:45:53 +0200
commitd2ef14d25c3b26d3354193a5bcc800d9dff87af2 (patch)
tree825f55b226d38772643d3cc618c88811861dcd16
parentd99dd52609e0ea49a299c9935e808c891968acc0 (diff)
downloadmariadb-git-d2ef14d25c3b26d3354193a5bcc800d9dff87af2.tar.gz
cleanup: fix a comment
-rw-r--r--include/my_base.h2
-rw-r--r--sql/structs.h7
-rw-r--r--sql/table.cc32
3 files changed, 17 insertions, 24 deletions
diff --git a/include/my_base.h b/include/my_base.h
index 1317639c528..ce8233ffa8f 100644
--- a/include/my_base.h
+++ b/include/my_base.h
@@ -560,7 +560,7 @@ typedef ulong key_part_map;
#define HA_STATE_KEY_CHANGED 128
#define HA_STATE_WRITE_AT_END 256 /* set in _ps_find_writepos */
#define HA_STATE_BUFF_SAVED 512 /* If current keybuff is info->buff */
-#define HA_STATE_ROW_CHANGED 1024 /* To invalide ROW cache */
+#define HA_STATE_ROW_CHANGED 1024 /* To invalidate ROW cache */
#define HA_STATE_EXTEND_BLOCK 2048
#define HA_STATE_RNEXT_SAME 4096 /* rnext_same occupied lastkey2 */
diff --git a/sql/structs.h b/sql/structs.h
index e51f3e0fe3a..3e174345e34 100644
--- a/sql/structs.h
+++ b/sql/structs.h
@@ -64,7 +64,9 @@ typedef struct st_keyfile_info { /* used with ha_info() */
typedef struct st_key_part_info { /* Info about a key part */
- Field *field;
+ Field *field; /* the Field object for the
+ indexed part of the original table
+ Field. NOT the original Field */
uint offset; /* offset in record (from 0) */
uint null_offset; /* Offset to null_bit in record */
/* Length of key part in bytes, excluding NULL flag and length bytes */
@@ -77,8 +79,7 @@ typedef struct st_key_part_info { /* Info about a key part */
*/
uint16 store_length;
uint16 key_type;
- /* Fieldnr begins counting from 1 */
- uint16 fieldnr; /* Fieldnum in UNIREG */
+ uint16 fieldnr; /* Fieldnr begins counting from 1 */
uint16 key_part_flag; /* 0 or HA_REVERSE_SORT */
uint8 type;
uint8 null_bit; /* Position to null_bit */
diff --git a/sql/table.cc b/sql/table.cc
index 07e2876f5ba..3e8a1b2e508 100644
--- a/sql/table.cc
+++ b/sql/table.cc
@@ -2417,19 +2417,13 @@ end:
@brief
Unpack the definition of a virtual column from its linear representation
- @param
- thd The thread object
- @param
- mem_root The mem_root object where to allocated memory
- @param
- table The table containing the virtual column
- @param
- field The field for the virtual
- @param
- vcol_expr The string representation of the defining expression
- @param[out]
- error_reported The flag to inform the caller that no other error
- messages are to be generated
+ @param thd The thread object
+ @param mem_root The mem_root object where to allocated memory
+ @param table The table containing the virtual column
+ @param field The field for the virtual
+ @param vcol_expr The string representation of the defining expression
+ @param[out] error_reported The flag to inform the caller that no other error
+ messages are to be generated
@details
The function takes string representation 'vcol_expr' of the defining
@@ -2441,13 +2435,11 @@ end:
it is created in table->memroot within the special arena TABLE::expr_arena.
@note
- Before passing 'vcol_expr" to the parser the function embraces it in
- parenthesis and prepands it a special keyword.
-
- @retval
- FALSE If a success
- @retval
- TRUE Otherwise
+ Before passing 'vcol_expr' to the parser the function wraps it in
+ parentheses and prepends a special keyword.
+
+ @retval FALSE If a success
+ @retval TRUE Otherwise
*/
bool unpack_vcol_info_from_frm(THD *thd,
MEM_ROOT *mem_root,