Safe Haskell | Safe-Inferred |
---|
Rewrite character identifiers for UGen.ID
graphs.
- greek_letters :: [(Char, Char, String)]
- type Name_Supply = [Char]
- greek_letters_nm :: Name_Supply
- rewrite :: Name_Supply -> String -> String
- hsc3_id_rewrite :: String -> String
- hsc3_id_clear :: String -> String
- hsc3_id_rewrite_preprocessor :: FilePath -> FilePath -> FilePath -> IO ()
- hsc3_id_rewrite_inplace :: FilePath -> IO ()
Greek letters
greek_letters :: [(Char, Char, String)]Source
Table of greek letters (upper-case,lower-case,name).
length greek_letters == 24 (['
type Name_Supply = [Char]Source
Indefinite sequence of character identifiers.
greek_letters_nm :: Name_SupplySource
take 4 greek_letters_nm == ['
Rewriters
rewrite :: Name_Supply -> String -> StringSource
Rewrite each haskell letter character literal at string l with values from the character supply s.
rewrite ['
hsc3_id_rewrite :: String -> StringSource
hsc3_id_rewrite "'a','.','a'" == "'
hsc3_id_clear :: String -> StringSource
IO
hsc3_id_rewrite_preprocessor :: FilePath -> FilePath -> FilePath -> IO ()Source
File based (haskell pre-processor) variant of hsc3_id_rewrite
.
hsc3_id_rewrite_inplace :: FilePath -> IO ()Source
File based (inplace) variant of hsc3_id_rewrite
. Copies file
to ~
suffix and replaces initial file.
let fn = "/home/rohan/sw/hsc3-graphs/gr/resonant-dust.hs" in hsc3_id_rewrite_file fn