mkName

constructs a simple, namespace unaware name. If the name is in prefix:localpart form and the prefix is not empty the name is split internally into a prefix and a local part.
Smart constructor for Name
Generate a capturable name. Occurrences of such names will be resolved according to the Haskell scoping rules at the occurrence site. For example:
f = [| pi + $(varE (mkName "pi")) |]
...
g = let pi = 3 in $f
In this case, g is desugared to
g = Prelude.pi + 3
Note that mkName may be used with qualified names:
mkName "Prelude.pi"
See also dyn for a useful combinator. The above example could be rewritten using dyn as
f = [| pi + $(dyn "pi") |]
The Range' sets the definition site of the name, not the use site.
Create a name from a string.
Make a name FunPtr
O(1). Builds a reified Name instance from the given name function. (cf. reifyName, mkNameWith)
Generate a name in the given case style taking into account the reserved word of the language. Note that despite the fact that those name are mainly to be used in code rendering (type Doc), we return a String here to allow further manipulation of the name (like disambiguation) which is not possible in the Doc type. Examples:
>>> mkName [] LowerCase "FooBAR"
"foobar"
>>> mkName [] UpperCase "FooBAR"
"FOOBAR"
>>> mkName [] SnakeCase "FooBAR"
"foo_bar"
>>> mkName [] CamelCase "FooBAR"
"FooBAR"
>>> mkName [] CamelCase "Foo_bar"
"FooBar"
>>> mkName [] MixedCase "FooBAR"
"fooBAR"
>>> mkName ["foobar"] LowerCase "FooBAR"
"foobar_"
>>> mkName ["foobar", "foobar_"] LowerCase "FooBAR"
"foobar__"
Make a Name from some kind of string.