Skip to content

bcpow issue with large exponent #16674

@devnexen

Description

@devnexen

Description

The following code:

<?php
bcpow(10, PHP_INT_MAX, 1);
?>

Resulted in this output:

<After a dozen of seconds>
PHP Fatal error:  Allowed memory size of 18446744073709551615 bytes exhausted

But I expected this output instead:

PHP Version

PHP >=8.2

Operating System

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions