Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop support for PHP 7.4 #172

Merged
merged 3 commits into from
Dec 15, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
strategy:
fail-fast: false
matrix:
php: [7.4, 8.0, 8.1, 8.2, 8.3]
php: [8.0, 8.1, 8.2, 8.3]
use-opcache: [true, false]

steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
shell: cmd
strategy:
matrix:
version: ['7.4', '8.0', '8.1', '8.2']
version: ['8.0', '8.1', '8.2']
arch: [x64]
ts: [ts]
runs-on: windows-2019
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Build
.deps
*.dep
*.lo
*.la
.libs
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# JsonPath-PHP - extension for PHP 7.4+
# JsonPath-PHP - extension for PHP 8.0+

[![Build status](https://github.com/supermetrics-public/pecl-jsonpath/workflows/Build/badge.svg)](https://github.com/supermetrics-public/pecl-jsonpath/actions?query=workflow%3ABuild)
![Code coverage](https://img.shields.io/endpoint?url=https://gist.githubusercontent.com/crocodele/5ceb08845fe95635fc41af2f4c86c631/raw/pecl-jsonpath__main.json&labelColor=343940)
Expand Down
4 changes: 0 additions & 4 deletions jsonpath.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,7 @@ void print_lex_tokens(struct jpath_token lex_tok[], int lex_tok_count, const cha
zend_class_entry* jsonpath_ce;
zend_class_entry* jsonpath_exception_ce;

#if PHP_VERSION_ID < 80000
#include "jsonpath_legacy_arginfo.h"
#else
#include "jsonpath_arginfo.h"
#endif

#define LEX_TOK_ARR_LEN 64

Expand Down
8 changes: 1 addition & 7 deletions jsonpath.stub.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,16 @@

/**
* @generate-class-entries
* @generate-legacy-arginfo
*/

namespace JsonPath;

class JsonPath
{
/**
* @param array $data
* @param string $expression
*
* @return array|bool
*
* @throws JsonPathException
*/
public function find(array $data, string $expression): array|bool;
public function find(array $data, string $expression): array|false;
}

class JsonPathException extends \RuntimeException
Expand Down
4 changes: 2 additions & 2 deletions jsonpath_arginfo.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* This is a generated file, edit the .stub.php file instead.
* Stub hash: 27fbe76d157af97672d8d6e085e2c68684e1024b */
* Stub hash: 0c874327bc35f4dfd0da2120cb50e2b8d299e28b */

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_class_JsonPath_JsonPath_find, 0, 2, MAY_BE_ARRAY|MAY_BE_BOOL)
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_class_JsonPath_JsonPath_find, 0, 2, MAY_BE_ARRAY|MAY_BE_FALSE)
ZEND_ARG_TYPE_INFO(0, data, IS_ARRAY, 0)
ZEND_ARG_TYPE_INFO(0, expression, IS_STRING, 0)
ZEND_END_ARG_INFO()
Expand Down
41 changes: 0 additions & 41 deletions jsonpath_legacy_arginfo.h

This file was deleted.

2 changes: 1 addition & 1 deletion tools/build-packagexml.php
Original file line number Diff line number Diff line change
Expand Up @@ -340,7 +340,7 @@ class PackageXMLElement extends SimpleXMLElement
<dependencies>
<required>
<php>
<min>7.4.0</min>
<min>8.0.0</min>
</php>
<pearinstaller>
<min>1.10.0</min>
Expand Down