@@ -133,15 +133,15 @@ defmodule AWS.CodeGen.Types do
133133 end
134134
135135 # Unfortunately, gotta patch over auto-defining types that already exist in Elixir
136- defp shape_to_type ( :elixir , "String" , _ ) , do: "String.t()"
136+ defp shape_to_type ( :elixir , "String" , _ ) , do: "String.t() | Atom.t() "
137137 defp shape_to_type ( :erlang , "String" , _ ) , do: "string()"
138- defp shape_to_type ( :elixir , "string" , _ ) , do: "String.t()"
138+ defp shape_to_type ( :elixir , "string" , _ ) , do: "String.t() | Atom.t() "
139139 defp shape_to_type ( :erlang , "string" , _ ) , do: "string()"
140- defp shape_to_type ( :elixir , "Identifier" , _ ) , do: "String.t()"
140+ defp shape_to_type ( :elixir , "Identifier" , _ ) , do: "String.t() | Atom.t() "
141141 defp shape_to_type ( :erlang , "Identifier" , _ ) , do: "string()"
142- defp shape_to_type ( :elixir , "identifier" , _ ) , do: "String.t()"
142+ defp shape_to_type ( :elixir , "identifier" , _ ) , do: "String.t() | Atom.t() "
143143 defp shape_to_type ( :erlang , "identifier" , _ ) , do: "string()"
144- defp shape_to_type ( :elixir , "XmlString" <> _rest , _ ) , do: "String.t()"
144+ defp shape_to_type ( :elixir , "XmlString" <> _rest , _ ) , do: "String.t() | Atom.t() "
145145 defp shape_to_type ( :erlang , "XmlString" <> _rest , _ ) , do: "string"
146146 defp shape_to_type ( :elixir , "NullablePositiveInteger" , _ ) , do: "nil | non_neg_integer()"
147147 defp shape_to_type ( :erlang , "NullablePositiveInteger" , _ ) , do: "undefined | non_neg_integer()"
@@ -153,7 +153,7 @@ defmodule AWS.CodeGen.Types do
153153 defp shape_to_type ( _ , % Shape { type: "timestamp" } , _module_name ) , do: "non_neg_integer()"
154154 defp shape_to_type ( _ , % Shape { type: "map" } , _module_name ) , do: "map()"
155155 defp shape_to_type ( _ , % Shape { type: "blob" } , _module_name ) , do: "binary()"
156- defp shape_to_type ( :elixir , % Shape { type: "string" } , _module_name ) , do: "String.t()"
156+ defp shape_to_type ( :elixir , % Shape { type: "string" } , _module_name ) , do: "String.t() | Atom.t() "
157157 defp shape_to_type ( :erlang , % Shape { type: "string" } , _module_name ) , do: "string()"
158158 defp shape_to_type ( _ , % Shape { type: "integer" } , _module_name ) , do: "integer()"
159159 defp shape_to_type ( _ , % Shape { type: "boolean" } , _module_name ) , do: "boolean()"
@@ -314,9 +314,9 @@ defmodule AWS.CodeGen.Types do
314314 parameters ,
315315 fn parameter ->
316316 if not parameter . required do
317- ", String.t() | nil"
317+ ", String.t() | Atom.t() | nil"
318318 else
319- ", String.t()"
319+ ", String.t() | Atom.t() "
320320 end
321321 end
322322 )
0 commit comments