~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/option.cc

  • Committer: Brian Aker
  • Date: 2010-12-25 00:28:49 UTC
  • mto: This revision was merged to the branch mainline in revision 2031.
  • Revision ID: brian@tangent.org-20101225002849-g73mg6ihulajis0o
First pass in refactoring of the name of my_decimal.

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
#include "drizzled/internal/my_sys.h"
22
22
#include "drizzled/error.h"
23
23
#include "drizzled/option.h"
24
 
#include "drizzled/typelib.h"
25
24
 
26
25
#include <stdio.h>
27
26
#include <stdlib.h>
644
643
            return EXIT_OUT_OF_MEMORY;
645
644
          break;
646
645
        case GET_ENUM:
647
 
          if (((*(int*)result_pos)= opts->typelib->find_type(argument, 2) - 1) < 0)
 
646
          if (((*(int*)result_pos)= find_type(argument, opts->typelib, 2) - 1) < 0)
648
647
            return EXIT_ARGUMENT_INVALID;
649
648
          break;
650
649
        case GET_SET:
651
 
          *((uint64_t*)result_pos)= opts->typelib->find_typeset(argument, &err);
 
650
          *((uint64_t*)result_pos)= find_typeset(argument, opts->typelib, &err);
652
651
          if (err)
653
652
            return EXIT_ARGUMENT_INVALID;
654
653
          break;
1235
1234
                if (!(bit & llvalue))
1236
1235
                  continue;
1237
1236
                llvalue&= ~bit;
1238
 
                printf( llvalue ? "%s," : "%s\n", optp->typelib->get_type(nr));
 
1237
                printf( llvalue ? "%s," : "%s\n", get_type(optp->typelib, nr));
1239
1238
              }
1240
1239
            break;
1241
1240
          case GET_ENUM:
1242
 
            printf("%s\n", optp->typelib->get_type(*(uint*) value));
 
1241
            printf("%s\n", get_type(optp->typelib, *(uint*) value));
1243
1242
            break;
1244
1243
          case GET_STR:
1245
1244
          case GET_STR_ALLOC:                    /* fall through */