Skip to content

Commit 3c6a844

Browse files
driusanircmaxell
authored andcommitted
Fix type incompatiblity errors in memory manager
This updates the PHP memory manager based on the Native memory manager preprocessor, and simply changes the names of the malloc family function calls. A MemoryManager::load function is re-added to select the memory manager to use based on the loadtype passed.
1 parent d07107b commit 3c6a844

File tree

16 files changed

+2486
-2463
lines changed

16 files changed

+2486
-2463
lines changed

.phan/config.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,6 @@
3131
'PhanNonClassMethodCall',
3232
'PhanUndeclaredTypeReturnType',
3333
'PhanUndeclaredVariableDim',
34-
'PhanParamSignatureRealMismatchTooManyRequiredParameters',
35-
'PhanParamSignatureMismatch',
3634
'PhanTypeInvalidDimOffset',
3735
],
3836
];

ext/types/strlen.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

3-
// This file is generated and changes you make will be lost.
4-
// Change /compiler/ext/types/strlen.pre instead.
3+
# This file is generated, changes you make will be lost.
4+
# Make your changes in /compiler/ext/types/strlen.pre instead.
55

66
/*
77
* This file is part of PHP-Compiler, a PHP CFG Compiler for PHP code

lib/JIT.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22

3-
// This file is generated and changes you make will be lost.
4-
// Change /compiler/lib/JIT.pre instead.
3+
# This file is generated, changes you make will be lost.
4+
# Make your changes in /compiler/lib/JIT.pre instead.
55

66
/*
77
* This file is part of PHP-Compiler, a PHP CFG Compiler for PHP code
@@ -610,4 +610,4 @@ private function assignOperandValue(Operand $result, PHPLLVM\Value $value): void
610610
$result->addref();
611611
}
612612

613-
}
613+
}

lib/JIT/Builtin/Internal.php

Lines changed: 19 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,22 @@
11
<?php
22

3-
declare(strict_types=1);
3+
# This file is generated, changes you make will be lost.
4+
# Make your changes in /compiler/lib/JIT/Builtin/Internal.pre instead.
45

5-
/**
6-
* This file is part of PHP-Compiler, a PHP CFG Compiler for PHP code
7-
*
8-
* @copyright 2015 Anthony Ferrara. All rights reserved
9-
* @license MIT See LICENSE at the root of the project for more info
10-
*/
11-
12-
// Change /compiler/lib/JIT/Builtin/Internal.pre instead.
13-
14-
/*
15-
* This file is part of PHP-Compiler, a PHP CFG Compiler for PHP code
16-
*
17-
* @copyright 2015 Anthony Ferrara. All rights reserved
18-
* @license MIT See LICENSE at the root of the project for more info
19-
*/
20-
namespace PHPCompiler\JIT\Builtin;
21-
22-
use PHPCompiler\JIT\Builtin;
23-
24-
class Internal extends Builtin
25-
{
26-
public function register(): void
27-
{
28-
}
29-
}
6+
/*
7+
* This file is part of PHP-Compiler, a PHP CFG Compiler for PHP code
8+
*
9+
* @copyright 2015 Anthony Ferrara. All rights reserved
10+
* @license MIT See LICENSE at the root of the project for more info
11+
*/
12+
13+
namespace PHPCompiler\JIT\Builtin;
14+
15+
use PHPCompiler\JIT\Builtin;
16+
17+
class Internal extends Builtin {
18+
19+
public function register(): void {
20+
}
21+
22+
}

0 commit comments

Comments
 (0)