Skip to content

Commit 074a821

Browse files
nicolas-grekasSeldaekDannyvdSluijs
authored
Fix support for 32bits PHP (#817)
Fix #816 --------- Co-authored-by: Jordi Boggiano <[email protected]> Co-authored-by: Danny van der Sluijs <[email protected]>
1 parent 16b274c commit 074a821

File tree

3 files changed

+11
-4
lines changed

3 files changed

+11
-4
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

88
## [Unreleased]
9+
### Fixed
10+
- Fix support for 32bits PHP ([#817](https://github.com/jsonrainbow/json-schema/pull/817))
911

1012
## [6.4.0] - 2025-04-01
1113
### Added

phpstan-baseline.neon

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ parameters:
2525
count: 1
2626
path: src/JsonSchema/Constraints/BaseConstraint.php
2727

28+
-
29+
message: "#^Property JsonSchema\\\\Constraints\\\\BaseConstraint\\:\\:\\$errorMask \\(int\\<\\-1, 3\\>\\) does not accept int\\.$#"
30+
count: 1
31+
path: src/JsonSchema/Constraints/BaseConstraint.php
32+
2833
-
2934
message: "#^Property JsonSchema\\\\Constraints\\\\BaseConstraint\\:\\:\\$errors type has no value type specified in iterable type array\\.$#"
3035
count: 1

src/JsonSchema/Validator.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ class Validator extends BaseConstraint
2727
{
2828
public const SCHEMA_MEDIA_TYPE = 'application/schema+json';
2929

30-
public const ERROR_NONE = 0x00000000;
31-
public const ERROR_ALL = 0xFFFFFFFF;
32-
public const ERROR_DOCUMENT_VALIDATION = 0x00000001;
33-
public const ERROR_SCHEMA_VALIDATION = 0x00000002;
30+
public const ERROR_NONE = 0;
31+
public const ERROR_ALL = -1;
32+
public const ERROR_DOCUMENT_VALIDATION = 1;
33+
public const ERROR_SCHEMA_VALIDATION = 2;
3434

3535
/**
3636
* Validates the given data against the schema and returns an object containing the results

0 commit comments

Comments
 (0)