Merge remote-tracking branch 'origin/master'

This commit is contained in:
gouguoyin 2021-03-17 11:30:16 +08:00
commit 5a605637b0

View File

@ -2,7 +2,6 @@ package carbon
import (
"math"
"strconv"
)
var (
@ -102,7 +101,7 @@ func (c Carbon) ToChineseDayString() string {
x := (44*(c.Century()-1) + (c.Century()-1)/4 + 9) % 60
// 计算月基数m
m := (int(math.Pow(-1, float64(c.Month())))+1)/2*30 + (3*c.Month()-7)/5
index := (s/4*6 + 5*(s/4*3+u) + m + d + x) % 60
return stemsAndBranches[index-1]
}