Skip to content

Commit

Permalink
Convert to string using rune() again
Browse files Browse the repository at this point in the history
  • Loading branch information
QuLogic committed Jan 30, 2022
1 parent b270184 commit 5ffb525
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions base/untyped/lit.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import (
"go/token"
"math/big"
r "reflect"
"unicode/utf8"

"github.com/cosmos72/gomacro/base/output"
"github.com/cosmos72/gomacro/base/reflect"
Expand Down Expand Up @@ -128,9 +129,9 @@ again:

i, exact := constant.Int64Val(val)
if exact {
ret = string(i)
ret = rune(i)
} else {
ret = "\uFFFD"
ret = utf8.RuneError
}
}
case r.Ptr:
Expand Down

0 comments on commit 5ffb525

Please sign in to comment.