Skip to content

Commit

Permalink
Merge pull request #5 from eparadis/main
Browse files Browse the repository at this point in the history
bugfix: optionally match decimal points
  • Loading branch information
olistrik committed Oct 17, 2022
2 parents 47285f8 + 14e4678 commit 61782a8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions goskew.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,9 @@ func skew(input []byte, xytan float64, xztan float64, yztan float64) string {
xin, yin, zin := 0.0, 0.0, 0.0

// init the regular expressions
xreg, _ := regexp.Compile(`[xX](-?\d*\.\d*)`)
yreg, _ := regexp.Compile(`[yY](-?\d*\.\d*)`)
zreg, _ := regexp.Compile(`[zZ](-?\d*\.\d*)`)
xreg, _ := regexp.Compile(`[xX](-?\d*\.?\d*)`)
yreg, _ := regexp.Compile(`[yY](-?\d*\.?\d*)`)
zreg, _ := regexp.Compile(`[zZ](-?\d*\.?\d*)`)

for i, line := range lines {
gmatch, _ := regexp.MatchString(`G[0-1]`, line)
Expand Down

0 comments on commit 61782a8

Please sign in to comment.