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

Allow global reads #34

Open
tam7t opened this issue Nov 11, 2018 · 0 comments
Open

Allow global reads #34

tam7t opened this issue Nov 11, 2018 · 0 comments

Comments

@tam7t
Copy link
Owner

tam7t commented Nov 11, 2018

$ pancakeinfo -pkg unicode -pure=false
IsNumber              basic /usr/local/go/src/unicode/graphic.go:108:26
ToUpper               calls unicode.To
IsSpace               basic /usr/local/go/src/unicode/graphic.go:135:26
...
IsLetter              basic /usr/local/go/src/unicode/graphic.go:94:26

Basically all of these are pure so long as the global variables are never written to. Instead of special casing all of these with DefaultIgnoreRead, analyze should only mark global reads as impure when there is a path to a global write.

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

1 participant