From ea297654f4d619fa90b527d1b76a366594e3b951 Mon Sep 17 00:00:00 2001 From: DanielEScherzer Date: Tue, 24 Sep 2024 01:55:21 -0700 Subject: [PATCH] Zend/*: fix a bunch of typos (GH-16017) * Zend/*: fix a bunch of typos * Zend/tests/try/try_catch_finally_005.phpt: update string length --- Zend/tests/019.phpt | 10 +++++----- Zend/tests/bug27731.phpt | 2 +- Zend/tests/bug30162.phpt | 2 +- Zend/tests/bug30922.phpt | 6 +++--- Zend/tests/bug32322.phpt | 2 +- Zend/tests/bug34467.phpt | 2 +- Zend/tests/bug36513.phpt | 2 +- Zend/tests/bug37707.phpt | 4 ++-- Zend/tests/bug39003.phpt | 2 +- Zend/tests/bug39297.phpt | 10 +++++----- Zend/tests/bug43851.phpt | 2 +- Zend/tests/bug45742.phpt | 2 +- Zend/tests/bug54039.phpt | 12 ++++++------ Zend/tests/bug54043.phpt | 2 +- Zend/tests/bug54367.phpt | 4 ++-- Zend/tests/bug60536_005.phpt | 2 +- Zend/tests/bug63219.phpt | 2 +- Zend/tests/bug70805.phpt | 8 ++++---- Zend/tests/bug73987_2.phpt | 2 +- Zend/tests/bug80811.phpt | 2 +- Zend/tests/class_constants_006.phpt | 2 +- Zend/tests/class_constants_007.phpt | 2 +- Zend/tests/closure_042.phpt | 4 ++-- Zend/tests/closures/closure_from_callable_error.phpt | 4 ++-- Zend/tests/ctor_promotion_mixing.phpt | 2 +- Zend/tests/enum/empty-from.phpt | 2 +- Zend/tests/fe_fetch_dtor_exception.phpt | 2 +- ...ngs_compatible_float_literals_assignment_ops.phpt | 2 +- .../warnings_float_literals_assignment_ops.phpt | 2 +- ...arnings_string_float_literals_assignment_ops.phpt | 2 +- Zend/tests/foreach_011.phpt | 2 +- Zend/tests/foreach_012.phpt | 2 +- Zend/tests/foreach_013.phpt | 2 +- Zend/tests/foreach_014.phpt | 2 +- Zend/tests/foreach_015.phpt | 2 +- Zend/tests/foreach_016.phpt | 2 +- Zend/tests/foreach_017.phpt | 2 +- Zend/tests/gc_001.phpt | 2 +- Zend/tests/gc_002.phpt | 2 +- Zend/tests/instanceof_002.phpt | 2 +- ...ne_creates_object_with_independent_state_001.phpt | 2 +- ...ne_creates_object_with_independent_state_002.phpt | 2 +- ...ne_creates_object_with_independent_state_003.phpt | 2 +- Zend/tests/lazy_objects/convert_to_array.phpt | 2 +- Zend/tests/lazy_objects/dtor_called_if_init.phpt | 2 +- .../lazy_objects/dtor_not_called_if_not_init.phpt | 2 +- Zend/tests/lsb_005.phpt | 2 +- Zend/tests/ns_027.phpt | 2 +- Zend/tests/ns_058.phpt | 2 +- Zend/tests/ns_063.phpt | 2 +- .../property_hooks/invalid_hook_visibility.phpt | 2 +- Zend/tests/traits/bug60153.phpt | 2 +- Zend/tests/traits/bug63911.phpt | 2 +- Zend/tests/traits/bugs/abstract-methods04.phpt | 2 +- Zend/tests/traits/flattening003.phpt | 2 +- Zend/tests/traits/inheritance002.phpt | 2 +- Zend/tests/try/try_catch_finally_005.phpt | 4 ++-- .../type_declarations/dnf_types/variance/valid1.phpt | 2 +- .../intersection_types/variance/valid1.phpt | 2 +- .../literal_types/false_no_coercion_on_overload.phpt | 2 +- .../literal_types/true_no_coercion_on_overload.phpt | 2 +- Zend/zend.c | 2 +- Zend/zend_execute_API.c | 2 +- Zend/zend_float.h | 2 +- Zend/zend_lazy_objects.c | 4 ++-- Zend/zend_operators.h | 4 ++-- Zend/zend_verify_type_inference.h | 2 +- 67 files changed, 92 insertions(+), 92 deletions(-) diff --git a/Zend/tests/019.phpt b/Zend/tests/019.phpt index bab02dd565d..4bc9d6be530 100644 --- a/Zend/tests/019.phpt +++ b/Zend/tests/019.phpt @@ -50,7 +50,7 @@ foreach ($scalar_variables as $scalar_var) { // destroy the variable using unset unset( $scalar_var ); - // dump and see if its destroyed, expcted: NULL + // dump and see if its destroyed, expected: NULL var_dump( $scalar_var ); // check using isset to see if unset, expected: bool(false) @@ -165,11 +165,11 @@ foreach ($resources as $resource) { // unset the resource unset($resource); // check using isset() and empty() - var_dump( isset($resource) ); // expected: bool(flase) + var_dump( isset($resource) ); // expected: bool(false) var_dump( empty($resource) ); // expected: bool(true) // call isset() with two args, but one set var_dump( isset($resource, $temp_var) ); // expected: bool(false) - // uset the temp_var + // unset the temp_var unset($temp_var); // now the isset() with both the args as unset var_dump( isset($resource, $temp_var) ); // expected: bool(false); @@ -211,7 +211,7 @@ var_dump($point1); // dump the object // check the object and member that is not set var_dump( isset($point1) ); // expected: bool(true) var_dump( empty($point1) ); // expected: bool(false) -var_dump( isset($point1->$lable) ); //expected: bool(flase) +var_dump( isset($point1->$lable) ); //expected: bool(false) var_dump( empty($point1->$lable) ); //expected: bool(true) //set the member variable lable and check @@ -291,7 +291,7 @@ function test_unset1() { $static_var = 20; echo "value of static_var after new assignment: $static_var\n"; } -// call the functiont +// call the function test_unset1(); test_unset1(); test_unset1(); diff --git a/Zend/tests/bug27731.phpt b/Zend/tests/bug27731.phpt index 655fffd5158..db2af293129 100644 --- a/Zend/tests/bug27731.phpt +++ b/Zend/tests/bug27731.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #27731 (error_reporing() call inside @ block does not work correctly) +Bug #27731 (error_reporting() call inside @ block does not work correctly) --FILE-- --EXPECTF-- -Fatal error: Uncaught Error: Interface "RecurisiveFooFar" not found in %s:%d +Fatal error: Uncaught Error: Interface "RecursiveFooFar" not found in %s:%d Stack trace: #0 {main} thrown in %s on line %d diff --git a/Zend/tests/bug32322.phpt b/Zend/tests/bug32322.phpt index 6d444ac2b3b..1b8f7f5c1f4 100644 --- a/Zend/tests/bug32322.phpt +++ b/Zend/tests/bug32322.phpt @@ -44,7 +44,7 @@ class test { echo "Class " . $this -> myname . " destroyed at script end\n"; } else { - echo "Class " . $this -> myname . " destroyed beforce script end\n"; + echo "Class " . $this -> myname . " destroyed before script end\n"; } } } diff --git a/Zend/tests/bug34467.phpt b/Zend/tests/bug34467.phpt index e301291e3c4..141097bb638 100644 --- a/Zend/tests/bug34467.phpt +++ b/Zend/tests/bug34467.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #34467 (foreach + __get + __set incosistency) +Bug #34467 (foreach + __get + __set inconsistency) --FILE-- --EXPECT-- -clonned +cloned NO LEAK diff --git a/Zend/tests/bug39003.phpt b/Zend/tests/bug39003.phpt index 5f7c7849762..75180288264 100644 --- a/Zend/tests/bug39003.phpt +++ b/Zend/tests/bug39003.phpt @@ -11,7 +11,7 @@ class ClassName function test (OtherClassName $object) { } spl_autoload_register(function ($class) { - var_dump("__autload($class)"); + var_dump("__autoload($class)"); }); $obj = new ClassName; diff --git a/Zend/tests/bug39297.phpt b/Zend/tests/bug39297.phpt index 4c6cf02c3a1..77f32e4291c 100644 --- a/Zend/tests/bug39297.phpt +++ b/Zend/tests/bug39297.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #39297 (Memory corryption because of indirect modification of overloaded array) +Bug #39297 (Memory corruption because of indirect modification of overloaded array) --FILE-- children[$cannonicalName] = $value; + $canonicalName = strtolower($offset); + $this->children[$canonicalName] = $value; $value->parent = $this; } public function offsetGet($offset): mixed { echo "offsetGet()\n"; - $cannonicalName = strtolower($offset); - return $this->children[$cannonicalName]; + $canonicalName = strtolower($offset); + return $this->children[$canonicalName]; } } diff --git a/Zend/tests/bug43851.phpt b/Zend/tests/bug43851.phpt index 7b0de5b1179..da0e8b7dceb 100644 --- a/Zend/tests/bug43851.phpt +++ b/Zend/tests/bug43851.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #43851 (Memory corrution on reuse of assigned value) +Bug #43851 (Memory corruption on reuse of assigned value) --FILE-- --EXPECT-- diff --git a/Zend/tests/bug60536_005.phpt b/Zend/tests/bug60536_005.phpt index 8ba0e57456b..90547e3bc4d 100644 --- a/Zend/tests/bug60536_005.phpt +++ b/Zend/tests/bug60536_005.phpt @@ -12,7 +12,7 @@ trait THello1 { } // Protected and public are handle more strict with a warning then what is -// expected from normal inheritance since they can have easier coliding semantics +// expected from normal inheritance since they can have easier colliding semantics echo "PRE-CLASS-GUARD\n"; class SameNameInSubClassProducesNotice extends Base { use THello1; diff --git a/Zend/tests/bug63219.phpt b/Zend/tests/bug63219.phpt index 999be4a8534..0c262de4d7d 100644 --- a/Zend/tests/bug63219.phpt +++ b/Zend/tests/bug63219.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #63219 (Segfault when aliasing trait method when autoloader throws excpetion) +Bug #63219 (Segfault when aliasing trait method when autoloader throws exception) --FILE-- diff --git a/Zend/tests/bug73987_2.phpt b/Zend/tests/bug73987_2.phpt index f6861fa4da8..a8c83a79fe7 100644 --- a/Zend/tests/bug73987_2.phpt +++ b/Zend/tests/bug73987_2.phpt @@ -1,5 +1,5 @@ --TEST-- -Bug #73987 (Method compatibility check looks to original definition and not parent - nullabilty abstract) +Bug #73987 (Method compatibility check looks to original definition and not parent - nullability abstract) --FILE-- bindTo(new stdClass); $d(); $rm = new ReflectionFunction($d); -var_dump($rm->getClosureScopeClass()->name); //dummy sope is Closure +var_dump($rm->getClosureScopeClass()->name); //dummy scope is Closure //should have the same effect $d = $c->bindTo(new stdClass, NULL); $d(); $rm = new ReflectionFunction($d); -var_dump($rm->getClosureScopeClass()->name); //dummy sope is Closure +var_dump($rm->getClosureScopeClass()->name); //dummy scope is Closure echo "Done.\n"; ?> diff --git a/Zend/tests/closures/closure_from_callable_error.phpt b/Zend/tests/closures/closure_from_callable_error.phpt index d30e4fcfa28..c6fd1ff831f 100644 --- a/Zend/tests/closures/closure_from_callable_error.phpt +++ b/Zend/tests/closures/closure_from_callable_error.phpt @@ -140,7 +140,7 @@ catch (\Throwable $t) { echo "Wrong exception type thrown: ".get_class($t)." : ".$t->getMessage()."\n"; } -echo 'Subclass cannot closure over parant private static method'."\n"; +echo 'Subclass cannot closure over parent private static method'."\n"; try { $subFoo = new SubFoo; $fn = $subFoo->closePrivateStaticInvalid(); @@ -205,7 +205,7 @@ Non-existent method should fail Non-existent class should fail Non-existent function should fail Subclass cannot closure over parent private instance method -Subclass cannot closure over parant private static method +Subclass cannot closure over parent private static method Function scope cannot closure over protected instance method Function scope cannot closure over private instance method Access private instance method of parent object through "self::" to parent method diff --git a/Zend/tests/ctor_promotion_mixing.phpt b/Zend/tests/ctor_promotion_mixing.phpt index a527654e793..403df7d03b4 100644 --- a/Zend/tests/ctor_promotion_mixing.phpt +++ b/Zend/tests/ctor_promotion_mixing.phpt @@ -1,5 +1,5 @@ --TEST-- -Constructor promotiong mixed with other properties, parameters and code +Constructor promotion mixed with other properties, parameters and code --FILE-- size == sizeof(zend_fcall_info)); diff --git a/Zend/zend_float.h b/Zend/zend_float.h index 64ed97400c9..63e0f6f7f69 100644 --- a/Zend/zend_float.h +++ b/Zend/zend_float.h @@ -43,7 +43,7 @@ END_EXTERN_C() The current macros are currently only used on x86 and x86_64 architectures, on every other architecture, these macros expand to NOPs. This assumes that - other architectures do not have an internal precision and the operhand types + other architectures do not have an internal precision and the operand types define the computational precision of floating point operations. This assumption may be false, in that case, the author is interested in further details on the other platform. diff --git a/Zend/zend_lazy_objects.c b/Zend/zend_lazy_objects.c index c8e9fa1bfb3..6d84875ad5e 100644 --- a/Zend/zend_lazy_objects.c +++ b/Zend/zend_lazy_objects.c @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* Lazy objects are standard zend_object whose initialization is defered until +/* Lazy objects are standard zend_object whose initialization is deferred until * one of their properties backing store is accessed for the first time. * * This is implemented by using the same fallback mechanism as __get and __set @@ -303,7 +303,7 @@ ZEND_API zend_object *zend_object_make_lazy(zend_object *obj, } /* Objects become non-lazy if all properties are made non-lazy before - * initialization is triggerd. If the object has no properties to begin + * initialization is triggered. If the object has no properties to begin * with, this happens immediately. */ if (UNEXPECTED(!lazy_properties_count)) { return obj; diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index 45f9820c41b..98b10c2096c 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -484,10 +484,10 @@ ZEND_API int ZEND_FASTCALL zend_compare_symbol_tables(HashTable *ht1, HashTable ZEND_API int ZEND_FASTCALL zend_compare_arrays(zval *a1, zval *a2); ZEND_API int ZEND_FASTCALL zend_compare_objects(zval *o1, zval *o2); -/** Deprecatd in favor of ZEND_STRTOL() */ +/** Deprecated in favor of ZEND_STRTOL() */ ZEND_ATTRIBUTE_DEPRECATED ZEND_API int ZEND_FASTCALL zend_atoi(const char *str, size_t str_len); -/** Deprecatd in favor of ZEND_STRTOL() */ +/** Deprecated in favor of ZEND_STRTOL() */ ZEND_ATTRIBUTE_DEPRECATED ZEND_API zend_long ZEND_FASTCALL zend_atol(const char *str, size_t str_len); #define convert_to_null_ex(zv) convert_to_null(zv) diff --git a/Zend/zend_verify_type_inference.h b/Zend/zend_verify_type_inference.h index 20a4c376087..0add0193349 100644 --- a/Zend/zend_verify_type_inference.h +++ b/Zend/zend_verify_type_inference.h @@ -46,7 +46,7 @@ static void zend_verify_type_inference(zval *value, uint32_t type_mask, uint8_t if (Z_TYPE_P(value) == IS_INDIRECT) { if (!(type_mask & MAY_BE_INDIRECT)) { - ZEND_VERIFY_TYPE_INFERENCE_ERROR("mask 0x%x mising MAY_BE_INDIRECT", type_mask); + ZEND_VERIFY_TYPE_INFERENCE_ERROR("mask 0x%x missing MAY_BE_INDIRECT", type_mask); } value = Z_INDIRECT_P(value); }