Skip to content

Commit

Permalink
#137 - Add support of single return type false
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeckerson committed Feb 7, 2022
1 parent d994137 commit 49a3339
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions parser/zephir.lemon
Original file line number Diff line number Diff line change
Expand Up @@ -702,6 +702,14 @@ xx_method_return_type_item(R) ::= THIS . {
}
}

xx_method_return_type_item(R) ::= FALSE . {
{
zval type;
xx_ret_type(&type, XX_T_TYPE_FALSE);
xx_ret_return_type_item(&R, &type, NULL, 0, 0, status->scanner_state);
}
}

xx_method_return_type_item(R) ::= xx_parameter_type(T) NOT . {
xx_ret_return_type_item(&R, &T, NULL, 1, 0, status->scanner_state);
}
Expand Down Expand Up @@ -950,6 +958,10 @@ xx_parameter_type(R) ::= TYPE_MIXED . {
xx_ret_type(&R, XX_TYPE_MIXED);
}

xx_parameter_type(R) ::= TYPE_FALSE . {
xx_ret_type(&R, XX_TYPE_FALSE);
}

xx_parameter_type(R) ::= TYPE_OBJECT . {
xx_ret_type(&R, XX_TYPE_OBJECT);
}
Expand Down

0 comments on commit 49a3339

Please sign in to comment.