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

Use int64 for phone number #2

Merged
merged 1 commit into from
Oct 16, 2020
Merged

Use int64 for phone number #2

merged 1 commit into from
Oct 16, 2020

Conversation

Snawoot
Copy link
Contributor

@Snawoot Snawoot commented Oct 16, 2020

Size of int type in Go is platform dependent. On 64bit platforms it's equal to int64 and on 32bit platforms it's equal to int32.

Nine-digit long phone numbers require int64 for proper representation. This PR fixes actual phone number size on 32bit platforms enforcing 64bit field size for phone numbers.

@mrz1836
Copy link
Owner

mrz1836 commented Oct 16, 2020

@Snawoot looks good - but failed on CI build:

WARN [runner] Can't run linter goanalysis_metalinter: bodyclose: failed prerequisites: [buildssa@github.com/mrz1836/go-pipl [github.com/mrz1836/go-pipl.test]: analysis skipped: errors in package: [/home/travis/gopath/src/github.com/mrz1836/go-pipl/helpers.go:201:20: cannot use phoneNumber (variable of type int) as int64 value in assignment]] 
WARN [runner] Can't run linter unused: buildir: analysis skipped: errors in package: [/home/travis/gopath/src/github.com/mrz1836/go-pipl/helpers.go:201:20: cannot use phoneNumber (variable of type int) as int64 value in assignment] 
ERRO Running error: buildir: analysis skipped: errors in package: [/home/travis/gopath/src/github.com/mrz1836/go-pipl/helpers.go:201:20: cannot use phoneNumber (variable of type int) as int64 value in assignment] 

@mrz1836 mrz1836 self-assigned this Oct 16, 2020
@mrz1836 mrz1836 added the update General updates label Oct 16, 2020
@mrz1836 mrz1836 merged commit 05763f9 into mrz1836:master Oct 16, 2020
@mrz1836
Copy link
Owner

mrz1836 commented Oct 16, 2020

Released in v0.3.3

@Snawoot Snawoot deleted the fix_phone_size branch October 16, 2020 12:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
update General updates
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants