Skip to content

Integer type does not accept negative values #23

Description

@bpj

I noticed that the 'integer' type doesn't support negative values. Is this intentional? Perhaps two additional types 'negative_integer' and 'any_integer' to preserve backward compatibility?

FWIW in my private library of frequently used extra types I have

  • int: positive or negative integer.
  • pos_int: int * range(1, math.maxinteger) with an array_index alias
  • non_pos_int int * range(math.mininteger, 0)
  • neg_int'
  • non_neg_int
  • non_zero_int: int * -literal(0)
  • pos_num etc.
  • float, pos_float etc.

each with a \describe like "non-positive integer. Of course generated by looping over two sets of tables with parameters.

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions