|
Mantis - Quercus
|
|||||
| Viewing Issue Advanced Details | |||||
|
|
|||||
| ID: | Category: | Severity: | Reproducibility: | Date Submitted: | Last Update: |
| 3158 | minor | always | 12-12-08 09:07 | 12-12-08 11:23 | |
|
|
|||||
| Reporter: | koreth | Platform: | |||
| Assigned To: | nam | OS: | |||
| Priority: | normal | OS Version: | |||
| Status: | closed | Product Version: | 4.0.0 | ||
| Product Build: | Resolution: | fixed | |||
| Projection: | none | ||||
| ETA: | none | Fixed in Version: | 4.0.0 | ||
|
|
|||||
| Summary: | 0003158: Wrong type passed to array_slice() causes compile failure | ||||
| Description: |
<?php function foo() { $x = array(1,2,3); $min_range = 0; $max_range = count($x) - 1; $middle = (int) (($min_range + $max_range) / 2); $larger_value = key(array_slice($x, $middle + 1, 1, true)); } Fails to compile on the latest Resin Pro: [09:05:23.405] {resin-12} com.caucho.java.JavaCompileException: .../_array_0slice__php.java:65: array_slice(com.caucho.quercus.env.Env,com.caucho.quercus.env.ArrayValue,long,com.caucho.quercus.env.Value,boolean) in com.caucho.quercus.lib.ArrayModule cannot be applied to (com.caucho.quercus.env.Env,com.caucho.quercus.env.ArrayValue,double,com.caucho.quercus.env.Value,boolean) [09:05:23.405] {resin-12} v_larger_value = ArrayModule.key(_quercus_module_3.array_slice(env, v_x.toValue().toArrayValue(env), ((double) v_middle + 1L), qv_1_0, true)); |
||||
| Steps To Reproduce: | |||||
| Additional Information: | |||||
| Relationships | |||||
| Attached Files: | |||||
| Notes | |||||
|
|
|||||
|
|
||||