Avatar
@swift-main import Foundation enum Foo: Codable { case bar } let data = try! JSONEncoder().encode(Foo.bar) let string = String(data: data, encoding: .utf8)! print(string)