Skip to content

i32 impossible to set #23

Description

@MichalNemec

Truly awesome generator, kudos to you!

I have issue with i32

{
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 20,
              "maximum": 100,
              "minimum": 1
            }
          },

Whatever i do, i.e:

[type_mappings]
"Int32" = "i32"
"Integer" = "i32"

[generator.types.strategies]
"int32" = "i32"
"integer" = "i32"

i always get i64. https://github.com/gpu-cli/openapi-to-rust/blob/main/src/analysis.rs#L4564 does not take it into account.
Can i have some direction on how to achieve i32?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions