Remove MySQL 4.0 checks from several libraries, losing the VP dependency

This commit is contained in:
Brian Fraser
2012-07-19 13:19:26 -03:00
parent de625a873c
commit 64c14e18f4
4 changed files with 7 additions and 27 deletions

View File

@@ -26,8 +26,6 @@
# $tbl is the return value from the sub below, parse().
#
# And some subs have an optional $opts param which is a hashref of options.
# $opts->{mysql_version} is typically used, which is the return value from
# VersionParser->new()
package TableParser;
use strict;
@@ -420,12 +418,6 @@ sub get_keys {
my ( $type, $cols ) = $key =~ m/(?:USING (\w+))? \((.+)\)/;
my ( $special ) = $key =~ m/(FULLTEXT|SPATIAL)/;
$type = $type || $special || 'BTREE';
if ( $opts->{mysql_version} && $opts->{mysql_version} lt '4.1'
&& $engine =~ m/HEAP|MEMORY/i )
{
$type = 'HASH'; # MySQL pre-4.1 supports only HASH indexes on HEAP
}
my ($name) = $key =~ m/(PRIMARY|`[^`]*`)/;
my $unique = $key =~ m/PRIMARY|UNIQUE/ ? 1 : 0;
my @cols;