You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello. This is a trifle, but is there a specific reason for accepting *embed.FS and not embed.FS in ParseEmbedFontFrom func?
It still keeps a pointer inside. By default it is usually passed by value.
https://pkg.go.dev/embed
import "embed"
//go:embed hello.txt
var f embed.FS
data, _ := f.ReadFile("hello.txt")
print(string(data))
The text was updated successfully, but these errors were encountered:
sedyh
changed the title
ParseEmbedFontFrom accepts *embed.FS
ParseEmbedFontFrom and ParseEmbedFontFrom accepts *embed.FS
Sep 2, 2022
sedyh
changed the title
ParseEmbedFontFrom and ParseEmbedFontFrom accepts *embed.FS
ParseEmbedFontFrom accepts *embed.FS
Sep 2, 2022
Thanks for the report. Yeah, there's no particular reason, it looks like it should indeed be passed by value. I have other changes to make with the release of Ebitengine v2.4.0, so I'll fix it and tag a new version in a few days.
Hello. This is a trifle, but is there a specific reason for accepting *embed.FS and not embed.FS in ParseEmbedFontFrom func?
It still keeps a pointer inside. By default it is usually passed by value.
The text was updated successfully, but these errors were encountered: