Skip to content

Commit

Permalink
del flen
Browse files Browse the repository at this point in the history
  • Loading branch information
dawxy committed Jun 22, 2017
1 parent 94ba710 commit 828035c
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
3 changes: 1 addition & 2 deletions expression/builtin_time.go
Original file line number Diff line number Diff line change
Expand Up @@ -2024,7 +2024,6 @@ type makeDateFunctionClass struct {

func (c *makeDateFunctionClass) getFunction(args []Expression, ctx context.Context) (builtinFunc, error) {
tp := types.NewFieldType(mysql.TypeDate)
tp.Flen = 10
types.SetBinChsClnFlag(tp)
bf, err := newBaseBuiltinFuncWithTp(args, tp, ctx, tpInt, tpInt)
if err != nil {
Expand All @@ -2038,7 +2037,7 @@ type builtinMakeDateSig struct {
baseTimeBuiltinFunc
}

// eval evals a builtinMakeDateSig.
// evalTime evaluates a builtinMakeDateSig.
// See https://dev.mysql.com/doc/refman/5.7/en/date-and-time-functions.html#function_makedate
func (b *builtinMakeDateSig) evalTime(row []types.Datum) (d types.Time, isNull bool, err error) {
args := b.getArgs()
Expand Down
1 change: 0 additions & 1 deletion expression/builtin_time_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1239,7 +1239,6 @@ func (s *testEvaluatorSuite) TestMakeDate(c *C) {
c.Assert(tp.Charset, Equals, charset.CharsetBin)
c.Assert(tp.Collate, Equals, charset.CollationBin)
c.Assert(tp.Flag, Equals, uint(mysql.BinaryFlag))
c.Assert(tp.Flen, Equals, 10)
d, err := f.Eval(nil)
if t.getErr {
c.Assert(err, NotNil)
Expand Down

0 comments on commit 828035c

Please sign in to comment.