Skip to content

Add support for polarity (+/-) operator #2152

@piotrszul

Description

@piotrszul

Currently unary +/- operators are not supported which makes is it impossible (or difficult) use negative literals e.g x < -1 .

(FHIR R4 Exclusions)

Details

au.csiro.pathling.errors.InvalidUserInputError: Polarity operator is not supported

  • -3 != 3 [** testLiteralIntegerNotEqual]
  • -Patient.name.given.count() = -5 [** testPolarityPrecedence]
  • Patient.name.given.count() > -3 [** testLiteralIntegerGreaterThan]
  • 1 < -2 [** testLiteralIntegerLessThanFalse]
  • +1 < +2 [** testLiteralIntegerLessThanPolarityTrue]
  • -1 < 2 [** testLiteralIntegerLessThanPolarityFalse]
  • (-1).toString() [** testNegativeIntegerLiteralToString]

Metadata

Metadata

Assignees

No one assigned

    Labels

    fhirpathRelated to fhirpath reference implementationnew featureNew feature or request

    Projects

    Status

    Done

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions