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

Corrected type hints #7

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

mindplay-dk
Copy link

Per this thread, I understand that tool support is not a concern or priority for the FIG, so I don't expect this PR will be merged - a replacement package with corrected type-hints has been published and can be installed as mindplay/simple-cache now.

mindplay-dk and others added 3 commits November 24, 2016 16:10
add imports for `DateInterval` and `Traversable` for proper static inspections (phan, Storm, code-sniffer, etc.)
…e php >= 5.3 minimum requirement in `composer.json`
@ghost
Copy link

ghost commented Mar 21, 2017

+1

The return type of return (array) $result; (array) is incompatible with the return type declared by the interface Psr\SimpleCache\CacheInterface::getMultiple of type Psr\SimpleCache\iterable.

I'm also getting this error. Any chance this will be merged? If I require mindplay/simple-cache then anything using psr/simple-cache will break making the whole spec kinda useless.

@mindplay-dk
Copy link
Author

If I require mindplay/simple-cache then anything using psr/simple-cache will break

It won't - my package replaces the real package and is otherwise identical to it.

But yeah, it would be nice if we didn't need this crappy work-around.

@@ -55,10 +58,10 @@ public function clear();
/**
* Obtains multiple cache items by their unique keys.
*
* @param iterable $keys A list of keys that can obtained in a single operation.
* @param mixed $default Default value to return for keys that do not exist.
* @param array|Traversable $keys A list of keys that can obtained in a single operation.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that can be obtained (be is missing), right ?

@Geolim4
Copy link

Geolim4 commented Jun 24, 2017

@michaelcullum @dragoonis Is this PR mergeable ?? Thanks you :)

@dragoonis
Copy link
Member

We should revisit the use of strong types, and flexible types, once the conversation around #13 is resolved. Afterward then we'll know what is and isn't possible, in terms off strict and flexible typing.

@Jean85
Copy link
Member

Jean85 commented Oct 6, 2021

Does this makes still sense in the light of #24 + #25?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants