schochastics / dialrs

https://schochastics.github.io/dialrs/
Apache License 2.0
7 stars 1 forks source link

Mapping LETTERS - enhancement #1

Open chris-english opened 6 months ago

chris-english commented 6 months ago

(arrived here from your chronos post)

https://github.com/scumdogsteev/phonenumber/blob/master/R/letterToNumber.R to bring to light numbers represented by letters perhaps with an else on any(stringr::str_detect('1-800-FLOWERS', LETTERS)) [1] TRUE

I've made much much less headway on Rust and R, yet yesterday the US White House urged transition to memory safe base code, and one thinks Rust rather than Ruby. I'm a historian and code dabbler, but my history view says that nearly every problem in programming has been solved before...I'll go back to updating my Rust and try again.

schochastics commented 6 months ago

Could you be more specific in what you are asking for? the parse function does recognize numbers with letters already

dialrs::phone_parse("+1 1 800 FLOWERS",format = "International")
#> "+1 18003569377"

are you looking for something like this (not implemented atm)

dialrs::phone_has_letters("+1 1 800 FLOWERS)"
#> TRUE
dialrs::phone_has_letters("+1 1 800 123456)"
#> FALSE