Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

failed to evaluate const hicb & locb #869

Closed
seaChris opened this issue May 17, 2023 · 5 comments
Closed

failed to evaluate const hicb & locb #869

seaChris opened this issue May 17, 2023 · 5 comments

Comments

@seaChris
Copy link

seaChris commented May 17, 2023

Hi,

whenever I try to generate a documentation with swagger I get a failure from two constants out of this project.

This is my error:

2023/05/17 15:06:10 warning: failed to evaluate const locb at /home/vagrant/share/go/pkg/mod/github.com/pelletier/go-toml/[email protected]/internal/characters/utf8.go:183:2, strconv.ParseUint: parsing "b10000000": invalid syntax
2023/05/17 15:06:10 warning: failed to evaluate const hicb at /home/vagrant/share/go/pkg/mod/github.com/pelletier/go-toml/[email protected]/internal/characters/utf8.go:184:2, strconv.ParseUint: parsing "b10111111": invalid syntax

I use v2.07 of go-toml

@pelletier
Copy link
Owner

Hi, this seems like an issue with swagger. This code is internal to go-toml (and a slightly modified version of the standard library). Seems like they don't handle the binary form of constant literals.

@jianjianxu
Copy link

I met the same problem, how to fix it?

@pelletier
Copy link
Owner

If you are using swagger as well I suggest sending them a bug report to handle 0b prefixed constants. If not can you describe how you encountered the issue?

@jianjianxu
Copy link

thank u, I did use swagger, I have already sent the report

@pelletier
Copy link
Owner

Closing since the problem doesn't seem with go-toml.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants