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

Request: add support for void return type to hhvm.php7 settings (or php 7.1 settings) #7740

Closed
TysonAndre opened this issue Mar 21, 2017 · 0 comments

Comments

@TysonAndre
Copy link

HHVM Version

nightly/all, as of today

Standalone code, or other way to reproduce the problem

With the hhvm.php7.all=1 ini setting

<?php
class MyClass {
     function foo() : void { }
}

Related to #7544 - This was filed since I didn't see any issues for this when searching

Expected result

There should be an ini setting which makes void a valid (non-class) type hint in php compatibility mode (In files with the tag <?php)
(Not aware of any settings when looking at ini documentation)

Actual result

Uncaught TypeError: Value returned from method MyClass::foo() must be of type void, null given in test.php:3

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

No branches or pull requests

3 participants