Changeset: c9bff4383833 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=c9bff4383833 Modified Files: gdk/gdk_imprints.c Branch: Oct2014 Log Message:
Better check whether imprints can be created. And it's not an error if they can't. diffs (25 lines): diff --git a/gdk/gdk_imprints.c b/gdk/gdk_imprints.c --- a/gdk/gdk_imprints.c +++ b/gdk/gdk_imprints.c @@ -548,6 +548,12 @@ BATimprints(BAT *b) assert(BAThdense(b)); /* assert void head */ + /* we only create imprints for types that look like types we know */ + if (b->ttype != ATOMstorage(b->ttype) && + (ATOMnilptr(b->ttype) != ATOMnilptr(ATOMstorage(b->ttype)) || + BATatoms[b->ttype].atomCmp != BATatoms[ATOMstorage(b->ttype)].atomCmp)) + return NULL; /* doesn't look enough like base type */ + switch (ATOMstorage(b->T->type)) { case TYPE_bte: case TYPE_sht: @@ -557,8 +563,6 @@ BATimprints(BAT *b) case TYPE_dbl: break; default: /* type not supported */ - GDKerror("#BATimprints: col type not " - "suitable for imprints index.\n"); return NULL; /* do nothing */ } _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list