how can I create an enum with "." or "-" in their names? I want something like:
enum Options: String {
case option1, option2, option2.1, option3
}
Using backticks (``) doesn't work. Is there some work-around I can do?
Neither character can be part of an identifier name. See https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html for the grammar.
Like Gereon says, basically, you can't. It is a very archaic system. But if you can find a good emoji you like, that'll work.
Also, note that each one is an Option, not an Options.