From ec23f998ea38413cdea8e6c14644179b26d407b2 Mon Sep 17 00:00:00 2001 From: Daniil Gentili Date: Thu, 26 Oct 2023 17:00:29 +0200 Subject: [PATCH] Finalize all internal classes --- examples/TemplateChecker.php | 2 +- examples/TemplateScanner.php | 2 +- examples/plugins/ClassUnqualifier.php | 2 +- examples/plugins/FunctionCasingChecker.php | 4 ++-- examples/plugins/InternalChecker.php | 2 +- examples/plugins/PreventFloatAssignmentChecker.php | 4 ++-- examples/plugins/SafeArrayKeyChecker.php | 2 +- examples/plugins/StringChecker.php | 2 +- examples/plugins/composer-based/echo-checker/EchoChecker.php | 2 +- .../plugins/composer-based/echo-checker/PluginEntryPoint.php | 2 +- src/Psalm/Internal/Algebra.php | 2 +- src/Psalm/Internal/Algebra/FormulaGenerator.php | 2 +- src/Psalm/Internal/Analyzer/AlgebraAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/AttributesAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/ClassAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/ClassLikeNameOptions.php | 2 +- src/Psalm/Internal/Analyzer/ClosureAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/CommentAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/DataFlowNodeData.php | 2 +- src/Psalm/Internal/Analyzer/FunctionAnalyzer.php | 2 +- .../Internal/Analyzer/FunctionLike/ReturnTypeAnalyzer.php | 2 +- .../Internal/Analyzer/FunctionLike/ReturnTypeCollector.php | 2 +- src/Psalm/Internal/Analyzer/InterfaceAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/IssueData.php | 2 +- src/Psalm/Internal/Analyzer/MethodAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/MethodComparator.php | 2 +- src/Psalm/Internal/Analyzer/NamespaceAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/ProjectAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/ScopeAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/Block/DoAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/Block/ForAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Block/ForeachAnalyzer.php | 2 +- .../Analyzer/Statements/Block/IfConditionalAnalyzer.php | 2 +- .../Analyzer/Statements/Block/IfElse/ElseAnalyzer.php | 2 +- .../Analyzer/Statements/Block/IfElse/ElseIfAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Block/IfElse/IfAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Block/IfElseAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/Block/LoopAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Block/SwitchAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Block/SwitchCaseAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/Block/TryAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Block/WhileAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/BreakAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/ContinueAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/EchoAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Expression/ArrayAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/ArrayCreationInfo.php | 2 +- .../Analyzer/Statements/Expression/AssertionFinder.php | 2 +- .../Expression/Assignment/ArrayAssignmentAnalyzer.php | 2 +- .../Statements/Expression/Assignment/AssignedProperty.php | 2 +- .../Assignment/InstancePropertyAssignmentAnalyzer.php | 2 +- .../Assignment/StaticPropertyAssignmentAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/AssignmentAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/BinaryOp/AndAnalyzer.php | 2 +- .../Statements/Expression/BinaryOp/ArithmeticOpAnalyzer.php | 2 +- .../Statements/Expression/BinaryOp/CoalesceAnalyzer.php | 2 +- .../Statements/Expression/BinaryOp/ConcatAnalyzer.php | 2 +- .../Expression/BinaryOp/NonComparisonOpAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/BinaryOp/OrAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/BinaryOpAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/BitwiseNotAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/BooleanNotAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/Call/ArgumentAnalyzer.php | 2 +- .../Statements/Expression/Call/ArgumentMapPopulator.php | 2 +- .../Analyzer/Statements/Expression/Call/ArgumentsAnalyzer.php | 2 +- .../Expression/Call/ArrayFunctionArgumentsAnalyzer.php | 2 +- .../Expression/Call/ClassTemplateParamCollector.php | 2 +- .../Statements/Expression/Call/FunctionCallAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/Call/FunctionCallInfo.php | 2 +- .../Expression/Call/FunctionCallReturnTypeFetcher.php | 2 +- .../Statements/Expression/Call/Method/AtomicCallContext.php | 2 +- .../Expression/Call/Method/AtomicMethodCallAnalysisResult.php | 2 +- .../Expression/Call/Method/AtomicMethodCallAnalyzer.php | 2 +- .../Call/Method/ExistingAtomicMethodCallAnalyzer.php | 2 +- .../Expression/Call/Method/MethodCallProhibitionAnalyzer.php | 2 +- .../Expression/Call/Method/MethodCallPurityAnalyzer.php | 2 +- .../Expression/Call/Method/MethodCallReturnTypeFetcher.php | 2 +- .../Expression/Call/Method/MethodVisibilityAnalyzer.php | 2 +- .../Expression/Call/Method/MissingMethodCallHandler.php | 2 +- .../Statements/Expression/Call/MethodCallAnalyzer.php | 2 +- .../Statements/Expression/Call/NamedFunctionCallHandler.php | 2 +- .../Analyzer/Statements/Expression/Call/NewAnalyzer.php | 2 +- .../Statements/Expression/Call/StaticCallAnalyzer.php | 2 +- .../Expression/Call/StaticMethod/AtomicStaticCallAnalyzer.php | 2 +- .../Call/StaticMethod/ExistingAtomicStaticCallAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Expression/CastAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/ClassConstAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Expression/CloneAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Expression/EmptyAnalyzer.php | 2 +- .../Statements/Expression/EncapsulatedStringAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Expression/EvalAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Expression/ExitAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/ExpressionIdentifier.php | 2 +- .../Statements/Expression/Fetch/ArrayFetchAnalyzer.php | 2 +- .../Expression/Fetch/AtomicPropertyFetchAnalyzer.php | 2 +- .../Statements/Expression/Fetch/ConstFetchAnalyzer.php | 2 +- .../Expression/Fetch/InstancePropertyFetchAnalyzer.php | 2 +- .../Expression/Fetch/StaticPropertyFetchAnalyzer.php | 2 +- .../Statements/Expression/Fetch/VariableFetchAnalyzer.php | 2 +- .../Statements/Expression/IncDecExpressionAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/IncludeAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/InstanceofAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Expression/IssetAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/MagicConstAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Expression/MatchAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/NullsafeAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Expression/PrintAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/SimpleTypeInferer.php | 2 +- .../Analyzer/Statements/Expression/TernaryAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/UnaryPlusMinusAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/Expression/YieldAnalyzer.php | 2 +- .../Analyzer/Statements/Expression/YieldFromAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/ExpressionAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/GlobalAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/ReturnAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/StaticAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/ThrowAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/Statements/UnsetAnalyzer.php | 2 +- .../Internal/Analyzer/Statements/UnusedAssignmentRemover.php | 2 +- src/Psalm/Internal/Analyzer/StatementsAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/TraitAnalyzer.php | 2 +- src/Psalm/Internal/Analyzer/TypeAnalyzer.php | 2 +- src/Psalm/Internal/Cache.php | 2 +- src/Psalm/Internal/Clause.php | 2 +- src/Psalm/Internal/Codebase/Analyzer.php | 2 +- src/Psalm/Internal/Codebase/ClassLikes.php | 2 +- src/Psalm/Internal/Codebase/ConstantTypeResolver.php | 2 +- src/Psalm/Internal/Codebase/Functions.php | 2 +- src/Psalm/Internal/Codebase/InternalCallMapHandler.php | 2 +- src/Psalm/Internal/Codebase/Methods.php | 2 +- src/Psalm/Internal/Codebase/Populator.php | 2 +- src/Psalm/Internal/Codebase/Properties.php | 2 +- src/Psalm/Internal/Codebase/PropertyMap.php | 2 +- src/Psalm/Internal/Codebase/ReferenceMapGenerator.php | 2 +- src/Psalm/Internal/Codebase/Reflection.php | 2 +- src/Psalm/Internal/Codebase/Scanner.php | 2 +- src/Psalm/Internal/Codebase/TaintFlowGraph.php | 2 +- src/Psalm/Internal/Codebase/VariableUseGraph.php | 2 +- src/Psalm/Internal/DataFlow/Path.php | 2 +- src/Psalm/Internal/DataFlow/TaintSink.php | 2 +- src/Psalm/Internal/DataFlow/TaintSource.php | 2 +- src/Psalm/Internal/Diff/ClassStatementsDiffer.php | 2 +- src/Psalm/Internal/Diff/DiffElem.php | 2 +- src/Psalm/Internal/Diff/FileDiffer.php | 2 +- src/Psalm/Internal/Diff/FileStatementsDiffer.php | 2 +- src/Psalm/Internal/Diff/NamespaceStatementsDiffer.php | 2 +- src/Psalm/Internal/EventDispatcher.php | 2 +- .../Internal/ExecutionEnvironment/BuildInfoCollector.php | 2 +- src/Psalm/Internal/ExecutionEnvironment/GitInfoCollector.php | 2 +- .../Internal/FileManipulation/ClassDocblockManipulator.php | 2 +- src/Psalm/Internal/FileManipulation/CodeMigration.php | 2 +- .../Internal/FileManipulation/FileManipulationBuffer.php | 2 +- .../Internal/FileManipulation/FunctionDocblockManipulator.php | 2 +- .../Internal/FileManipulation/PropertyDocblockManipulator.php | 2 +- src/Psalm/Internal/Fork/ForkProcessDoneMessage.php | 2 +- src/Psalm/Internal/Fork/ForkProcessErrorMessage.php | 2 +- src/Psalm/Internal/Fork/ForkTaskDoneMessage.php | 2 +- src/Psalm/Internal/Fork/Pool.php | 2 +- src/Psalm/Internal/Fork/PsalmRestarter.php | 2 +- src/Psalm/Internal/Json/Json.php | 2 +- src/Psalm/Internal/LanguageServer/Client/TextDocument.php | 2 +- src/Psalm/Internal/LanguageServer/Client/Workspace.php | 2 +- src/Psalm/Internal/LanguageServer/ClientConfiguration.php | 2 +- src/Psalm/Internal/LanguageServer/ClientHandler.php | 2 +- src/Psalm/Internal/LanguageServer/IdGenerator.php | 2 +- src/Psalm/Internal/LanguageServer/LanguageClient.php | 2 +- src/Psalm/Internal/LanguageServer/LanguageServer.php | 2 +- src/Psalm/Internal/LanguageServer/Message.php | 2 +- src/Psalm/Internal/LanguageServer/PHPMarkdownContent.php | 2 +- src/Psalm/Internal/LanguageServer/Progress.php | 2 +- src/Psalm/Internal/LanguageServer/ProtocolStreamReader.php | 2 +- src/Psalm/Internal/LanguageServer/ProtocolStreamWriter.php | 2 +- .../LanguageServer/Provider/ClassLikeStorageCacheProvider.php | 2 +- .../LanguageServer/Provider/FileReferenceCacheProvider.php | 2 +- .../LanguageServer/Provider/FileStorageCacheProvider.php | 2 +- .../Internal/LanguageServer/Provider/ParserCacheProvider.php | 2 +- .../Internal/LanguageServer/Provider/ProjectCacheProvider.php | 2 +- src/Psalm/Internal/LanguageServer/Reference.php | 2 +- src/Psalm/Internal/LanguageServer/Server/TextDocument.php | 2 +- src/Psalm/Internal/LanguageServer/Server/Workspace.php | 2 +- src/Psalm/Internal/MethodIdentifier.php | 2 +- src/Psalm/Internal/PhpTraverser/CustomTraverser.php | 2 +- src/Psalm/Internal/PhpVisitor/AssignmentMapVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/CheckTrivialExprVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/CloningVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/ConditionCloningVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/NodeCleanerVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/NodeCounterVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/OffsetShifterVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/ParamReplacementVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/PartialParserVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/Reflector/AttributeResolver.php | 2 +- .../Internal/PhpVisitor/Reflector/ClassLikeDocblockParser.php | 2 +- .../Internal/PhpVisitor/Reflector/ClassLikeNodeScanner.php | 2 +- .../Internal/PhpVisitor/Reflector/ExpressionResolver.php | 2 +- src/Psalm/Internal/PhpVisitor/Reflector/ExpressionScanner.php | 2 +- .../PhpVisitor/Reflector/FunctionLikeDocblockParser.php | 2 +- .../PhpVisitor/Reflector/FunctionLikeDocblockScanner.php | 2 +- .../Internal/PhpVisitor/Reflector/FunctionLikeNodeScanner.php | 2 +- src/Psalm/Internal/PhpVisitor/Reflector/TypeHintResolver.php | 2 +- src/Psalm/Internal/PhpVisitor/ReflectorVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/ShortClosureVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/SimpleNameResolver.php | 2 +- src/Psalm/Internal/PhpVisitor/TraitFinder.php | 2 +- src/Psalm/Internal/PhpVisitor/TypeMappingVisitor.php | 2 +- src/Psalm/Internal/PhpVisitor/YieldTypeCollector.php | 2 +- src/Psalm/Internal/PluginManager/Command/DisableCommand.php | 2 +- src/Psalm/Internal/PluginManager/Command/EnableCommand.php | 2 +- src/Psalm/Internal/PluginManager/Command/ShowCommand.php | 2 +- src/Psalm/Internal/PluginManager/ComposerLock.php | 2 +- src/Psalm/Internal/PluginManager/ConfigFile.php | 2 +- src/Psalm/Internal/PluginManager/PluginList.php | 2 +- src/Psalm/Internal/PluginManager/PluginListFactory.php | 2 +- .../Internal/Provider/AddRemoveTaints/HtmlFunctionTainter.php | 2 +- src/Psalm/Internal/Provider/ClassLikeStorageProvider.php | 2 +- src/Psalm/Internal/Provider/FakeFileProvider.php | 2 +- src/Psalm/Internal/Provider/FileReferenceProvider.php | 2 +- src/Psalm/Internal/Provider/FileStorageProvider.php | 2 +- src/Psalm/Internal/Provider/FunctionExistenceProvider.php | 2 +- src/Psalm/Internal/Provider/FunctionParamsProvider.php | 2 +- src/Psalm/Internal/Provider/FunctionReturnTypeProvider.php | 2 +- src/Psalm/Internal/Provider/MethodExistenceProvider.php | 2 +- src/Psalm/Internal/Provider/MethodParamsProvider.php | 2 +- src/Psalm/Internal/Provider/MethodReturnTypeProvider.php | 2 +- src/Psalm/Internal/Provider/MethodVisibilityProvider.php | 2 +- src/Psalm/Internal/Provider/NodeDataProvider.php | 2 +- src/Psalm/Internal/Provider/PropertyExistenceProvider.php | 2 +- src/Psalm/Internal/Provider/PropertyTypeProvider.php | 2 +- .../PropertyTypeProvider/DomDocumentPropertyTypeProvider.php | 2 +- src/Psalm/Internal/Provider/PropertyVisibilityProvider.php | 2 +- src/Psalm/Internal/Provider/Providers.php | 2 +- .../ReturnTypeProvider/ArrayChunkReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayColumnReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayCombineReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayFillKeysReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayFillReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayFilterReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayMapReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayMergeReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayPadReturnTypeProvider.php | 2 +- .../ArrayPointerAdjustmentReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayPopReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayRandReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayReduceReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArrayReverseReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArraySliceReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ArraySpliceReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/BasenameReturnTypeProvider.php | 2 +- .../ClosureFromCallableReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/DateReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/DateTimeModifyReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/DirnameReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/DomNodeAppendChild.php | 2 +- .../ReturnTypeProvider/FilterVarReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/FirstArgStringReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/GetClassMethodsReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/GetObjectVarsReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/HexdecReturnTypeProvider.php | 2 +- .../ImagickPixelColorReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/InArrayReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/IteratorToArrayReturnTypeProvider.php | 2 +- .../MbInternalEncodingReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/MinMaxReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/MktimeReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/ParseUrlReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/PdoStatementReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/PdoStatementSetFetchMode.php | 2 +- .../Provider/ReturnTypeProvider/PowReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/RandReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/RoundReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/SprintfReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/StrReplaceReturnTypeProvider.php | 2 +- .../Provider/ReturnTypeProvider/StrTrReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/TriggerErrorReturnTypeProvider.php | 2 +- .../ReturnTypeProvider/VersionCompareReturnTypeProvider.php | 2 +- src/Psalm/Internal/Provider/StatementsProvider.php | 2 +- src/Psalm/Internal/ReferenceConstraint.php | 2 +- src/Psalm/Internal/Scanner/ClassLikeDocblockComment.php | 2 +- src/Psalm/Internal/Scanner/DocblockParser.php | 2 +- src/Psalm/Internal/Scanner/FunctionDocblockComment.php | 2 +- src/Psalm/Internal/Scanner/ParsedDocblock.php | 2 +- src/Psalm/Internal/Scanner/PhpStormMetaScanner.php | 2 +- .../Internal/Scanner/UnresolvedConstant/ArrayOffsetFetch.php | 2 +- src/Psalm/Internal/Scanner/UnresolvedConstant/ArraySpread.php | 2 +- src/Psalm/Internal/Scanner/UnresolvedConstant/ArrayValue.php | 2 +- .../Internal/Scanner/UnresolvedConstant/ClassConstant.php | 2 +- src/Psalm/Internal/Scanner/UnresolvedConstant/Constant.php | 2 +- .../Internal/Scanner/UnresolvedConstant/EnumNameFetch.php | 2 +- .../Internal/Scanner/UnresolvedConstant/EnumValueFetch.php | 2 +- .../Internal/Scanner/UnresolvedConstant/KeyValuePair.php | 2 +- src/Psalm/Internal/Scanner/UnresolvedConstant/ScalarValue.php | 2 +- .../Scanner/UnresolvedConstant/UnresolvedAdditionOp.php | 2 +- .../Scanner/UnresolvedConstant/UnresolvedBitwiseAnd.php | 2 +- .../Scanner/UnresolvedConstant/UnresolvedBitwiseOr.php | 2 +- .../Scanner/UnresolvedConstant/UnresolvedBitwiseXor.php | 2 +- .../Scanner/UnresolvedConstant/UnresolvedConcatOp.php | 2 +- .../Scanner/UnresolvedConstant/UnresolvedDivisionOp.php | 2 +- .../Scanner/UnresolvedConstant/UnresolvedMultiplicationOp.php | 2 +- .../Scanner/UnresolvedConstant/UnresolvedSubtractionOp.php | 2 +- .../Internal/Scanner/UnresolvedConstant/UnresolvedTernary.php | 2 +- src/Psalm/Internal/Scanner/VarDocblockComment.php | 2 +- src/Psalm/Internal/Scope/CaseScope.php | 2 +- src/Psalm/Internal/Scope/FinallyScope.php | 2 +- src/Psalm/Internal/Scope/IfConditionalScope.php | 2 +- src/Psalm/Internal/Scope/IfScope.php | 2 +- src/Psalm/Internal/Scope/LoopScope.php | 2 +- src/Psalm/Internal/Scope/SwitchScope.php | 2 +- src/Psalm/Internal/Stubs/Generator/ClassLikeStubGenerator.php | 2 +- src/Psalm/Internal/Stubs/Generator/StubsGenerator.php | 2 +- src/Psalm/Internal/Type/ArrayType.php | 2 +- src/Psalm/Internal/Type/AssertionReconciler.php | 2 +- src/Psalm/Internal/Type/Comparator/ArrayTypeComparator.php | 2 +- src/Psalm/Internal/Type/Comparator/AtomicTypeComparator.php | 2 +- src/Psalm/Internal/Type/Comparator/CallableTypeComparator.php | 2 +- .../Internal/Type/Comparator/ClassLikeStringComparator.php | 2 +- src/Psalm/Internal/Type/Comparator/GenericTypeComparator.php | 2 +- src/Psalm/Internal/Type/Comparator/IntegerRangeComparator.php | 2 +- src/Psalm/Internal/Type/Comparator/KeyedArrayComparator.php | 2 +- src/Psalm/Internal/Type/Comparator/ObjectComparator.php | 2 +- src/Psalm/Internal/Type/Comparator/ScalarTypeComparator.php | 2 +- src/Psalm/Internal/Type/Comparator/TypeComparisonResult.php | 2 +- src/Psalm/Internal/Type/Comparator/UnionTypeComparator.php | 2 +- src/Psalm/Internal/Type/NegatedAssertionReconciler.php | 2 +- src/Psalm/Internal/Type/ParseTree/CallableParamTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/CallableTree.php | 2 +- .../Internal/Type/ParseTree/CallableWithReturnTypeTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/ConditionalTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/EncapsulationTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/FieldEllipsis.php | 2 +- src/Psalm/Internal/Type/ParseTree/GenericTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/IndexedAccessTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/IntersectionTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/KeyedArrayPropertyTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/KeyedArrayTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/MethodParamTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/MethodTree.php | 2 +- .../Internal/Type/ParseTree/MethodWithReturnTypeTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/NullableTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/Root.php | 2 +- src/Psalm/Internal/Type/ParseTree/TemplateAsTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/TemplateIsTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/UnionTree.php | 2 +- src/Psalm/Internal/Type/ParseTree/Value.php | 2 +- src/Psalm/Internal/Type/ParseTreeCreator.php | 2 +- src/Psalm/Internal/Type/SimpleAssertionReconciler.php | 2 +- src/Psalm/Internal/Type/SimpleNegatedAssertionReconciler.php | 2 +- src/Psalm/Internal/Type/TemplateBound.php | 2 +- src/Psalm/Internal/Type/TemplateInferredTypeReplacer.php | 2 +- src/Psalm/Internal/Type/TemplateResult.php | 2 +- src/Psalm/Internal/Type/TemplateStandinTypeReplacer.php | 2 +- src/Psalm/Internal/Type/TypeAlias/ClassTypeAlias.php | 2 +- src/Psalm/Internal/Type/TypeAlias/InlineTypeAlias.php | 2 +- src/Psalm/Internal/Type/TypeAlias/LinkableTypeAlias.php | 2 +- src/Psalm/Internal/Type/TypeCombination.php | 2 +- src/Psalm/Internal/Type/TypeCombiner.php | 2 +- src/Psalm/Internal/Type/TypeExpander.php | 2 +- src/Psalm/Internal/Type/TypeParser.php | 2 +- src/Psalm/Internal/Type/TypeTokenizer.php | 2 +- .../Internal/TypeVisitor/CanContainObjectTypeVisitor.php | 2 +- src/Psalm/Internal/TypeVisitor/ClasslikeReplacer.php | 2 +- src/Psalm/Internal/TypeVisitor/ContainsClassLikeVisitor.php | 2 +- src/Psalm/Internal/TypeVisitor/ContainsLiteralVisitor.php | 2 +- src/Psalm/Internal/TypeVisitor/ContainsStaticVisitor.php | 2 +- src/Psalm/Internal/TypeVisitor/FromDocblockSetter.php | 2 +- src/Psalm/Internal/TypeVisitor/TemplateTypeCollector.php | 2 +- src/Psalm/Internal/TypeVisitor/TypeChecker.php | 2 +- src/Psalm/Internal/TypeVisitor/TypeLocalizer.php | 2 +- src/Psalm/Internal/TypeVisitor/TypeScanner.php | 2 +- 368 files changed, 370 insertions(+), 370 deletions(-) diff --git a/examples/TemplateChecker.php b/examples/TemplateChecker.php index 55e65d2300f..ddaaab2baab 100644 --- a/examples/TemplateChecker.php +++ b/examples/TemplateChecker.php @@ -30,7 +30,7 @@ use function strtolower; use function trim; -class TemplateAnalyzer extends Psalm\Internal\Analyzer\FileAnalyzer +final class TemplateAnalyzer extends Psalm\Internal\Analyzer\FileAnalyzer { const VIEW_CLASS = 'Your\\View\\Class'; diff --git a/examples/TemplateScanner.php b/examples/TemplateScanner.php index d177f80e6b8..70c37470ca0 100644 --- a/examples/TemplateScanner.php +++ b/examples/TemplateScanner.php @@ -14,7 +14,7 @@ use function preg_match; use function trim; -class TemplateScanner extends Psalm\Internal\Scanner\FileScanner +final class TemplateScanner extends Psalm\Internal\Scanner\FileScanner { const VIEW_CLASS = 'Your\\View\\Class'; diff --git a/examples/plugins/ClassUnqualifier.php b/examples/plugins/ClassUnqualifier.php index 57a9f86da08..2c84f051ef1 100644 --- a/examples/plugins/ClassUnqualifier.php +++ b/examples/plugins/ClassUnqualifier.php @@ -12,7 +12,7 @@ use function strpos; use function strtolower; -class ClassUnqualifier implements AfterClassLikeExistenceCheckInterface +final class ClassUnqualifier implements AfterClassLikeExistenceCheckInterface { public static function afterClassLikeExistenceCheck( AfterClassLikeExistenceCheckEvent $event diff --git a/examples/plugins/FunctionCasingChecker.php b/examples/plugins/FunctionCasingChecker.php index 50cfc7358ff..f4147ab3f3f 100644 --- a/examples/plugins/FunctionCasingChecker.php +++ b/examples/plugins/FunctionCasingChecker.php @@ -21,7 +21,7 @@ /** * Checks that functions and methods are correctly-cased */ -class FunctionCasingChecker implements AfterFunctionCallAnalysisInterface, AfterMethodCallAnalysisInterface +final class FunctionCasingChecker implements AfterFunctionCallAnalysisInterface, AfterMethodCallAnalysisInterface { public static function afterMethodCallAnalysis(AfterMethodCallAnalysisEvent $event): void { @@ -99,6 +99,6 @@ public static function afterFunctionCallAnalysis(AfterFunctionCallAnalysisEvent } } -class IncorrectFunctionCasing extends PluginIssue +final class IncorrectFunctionCasing extends PluginIssue { } diff --git a/examples/plugins/InternalChecker.php b/examples/plugins/InternalChecker.php index 1ae5d8afee9..802edccf87d 100644 --- a/examples/plugins/InternalChecker.php +++ b/examples/plugins/InternalChecker.php @@ -12,7 +12,7 @@ use function strpos; -class InternalChecker implements AfterClassLikeAnalysisInterface +final class InternalChecker implements AfterClassLikeAnalysisInterface { /** @return null|false */ public static function afterStatementAnalysis(AfterClassLikeAnalysisEvent $event): ?bool diff --git a/examples/plugins/PreventFloatAssignmentChecker.php b/examples/plugins/PreventFloatAssignmentChecker.php index 18b5630efbc..5bc7b0765bb 100644 --- a/examples/plugins/PreventFloatAssignmentChecker.php +++ b/examples/plugins/PreventFloatAssignmentChecker.php @@ -12,7 +12,7 @@ /** * Prevents any assignment to a float value */ -class PreventFloatAssignmentChecker implements AfterExpressionAnalysisInterface +final class PreventFloatAssignmentChecker implements AfterExpressionAnalysisInterface { /** * Called after an expression has been checked @@ -40,6 +40,6 @@ public static function afterExpressionAnalysis(AfterExpressionAnalysisEvent $eve } } -class NoFloatAssignment extends PluginIssue +final class NoFloatAssignment extends PluginIssue { } diff --git a/examples/plugins/SafeArrayKeyChecker.php b/examples/plugins/SafeArrayKeyChecker.php index 5ea69772535..0360ed79155 100644 --- a/examples/plugins/SafeArrayKeyChecker.php +++ b/examples/plugins/SafeArrayKeyChecker.php @@ -7,7 +7,7 @@ use Psalm\Plugin\EventHandler\Event\AddRemoveTaintsEvent; use Psalm\Plugin\EventHandler\RemoveTaintsInterface; -class SafeArrayKeyChecker implements RemoveTaintsInterface +final class SafeArrayKeyChecker implements RemoveTaintsInterface { /** * Called to see what taints should be removed diff --git a/examples/plugins/StringChecker.php b/examples/plugins/StringChecker.php index 621997dd965..8366596ce33 100644 --- a/examples/plugins/StringChecker.php +++ b/examples/plugins/StringChecker.php @@ -16,7 +16,7 @@ use function strpos; use function strtolower; -class StringChecker implements AfterExpressionAnalysisInterface +final class StringChecker implements AfterExpressionAnalysisInterface { /** * Called after an expression has been checked diff --git a/examples/plugins/composer-based/echo-checker/EchoChecker.php b/examples/plugins/composer-based/echo-checker/EchoChecker.php index 668206c26e3..642e0a53e9c 100644 --- a/examples/plugins/composer-based/echo-checker/EchoChecker.php +++ b/examples/plugins/composer-based/echo-checker/EchoChecker.php @@ -11,7 +11,7 @@ use Psalm\Type\Atomic\TLiteralString; use Psalm\Type\Atomic\TString; -class EchoChecker implements AfterStatementAnalysisInterface +final class EchoChecker implements AfterStatementAnalysisInterface { /** * Called after a statement has been checked diff --git a/examples/plugins/composer-based/echo-checker/PluginEntryPoint.php b/examples/plugins/composer-based/echo-checker/PluginEntryPoint.php index 4d6102281e4..e83927e0d04 100644 --- a/examples/plugins/composer-based/echo-checker/PluginEntryPoint.php +++ b/examples/plugins/composer-based/echo-checker/PluginEntryPoint.php @@ -6,7 +6,7 @@ use Psalm\Plugin\RegistrationInterface; use SimpleXMLElement; -class PluginEntryPoint implements PluginEntryPointInterface +final class PluginEntryPoint implements PluginEntryPointInterface { public function __invoke(RegistrationInterface $registration, ?SimpleXMLElement $config = null): void { diff --git a/src/Psalm/Internal/Algebra.php b/src/Psalm/Internal/Algebra.php index d2b16a26c0f..43345dfd004 100644 --- a/src/Psalm/Internal/Algebra.php +++ b/src/Psalm/Internal/Algebra.php @@ -24,7 +24,7 @@ /** * @internal */ -class Algebra +final class Algebra { /** * @param array>> $all_types diff --git a/src/Psalm/Internal/Algebra/FormulaGenerator.php b/src/Psalm/Internal/Algebra/FormulaGenerator.php index c5d75f8829c..b6810291e5d 100644 --- a/src/Psalm/Internal/Algebra/FormulaGenerator.php +++ b/src/Psalm/Internal/Algebra/FormulaGenerator.php @@ -21,7 +21,7 @@ /** * @internal */ -class FormulaGenerator +final class FormulaGenerator { /** * @return list diff --git a/src/Psalm/Internal/Analyzer/AlgebraAnalyzer.php b/src/Psalm/Internal/Analyzer/AlgebraAnalyzer.php index 6fc52514aa3..5f721f5313e 100644 --- a/src/Psalm/Internal/Analyzer/AlgebraAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/AlgebraAnalyzer.php @@ -20,7 +20,7 @@ /** * @internal */ -class AlgebraAnalyzer +final class AlgebraAnalyzer { /** * This looks to see if there are any clauses in one formula that contradict diff --git a/src/Psalm/Internal/Analyzer/AttributesAnalyzer.php b/src/Psalm/Internal/Analyzer/AttributesAnalyzer.php index f5010ecd242..7b1eb545d72 100644 --- a/src/Psalm/Internal/Analyzer/AttributesAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/AttributesAnalyzer.php @@ -33,7 +33,7 @@ /** * @internal */ -class AttributesAnalyzer +final class AttributesAnalyzer { private const TARGET_DESCRIPTIONS = [ 1 => 'class', diff --git a/src/Psalm/Internal/Analyzer/ClassAnalyzer.php b/src/Psalm/Internal/Analyzer/ClassAnalyzer.php index bcd63764a0f..a37b4b7ad04 100644 --- a/src/Psalm/Internal/Analyzer/ClassAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/ClassAnalyzer.php @@ -106,7 +106,7 @@ /** * @internal */ -class ClassAnalyzer extends ClassLikeAnalyzer +final class ClassAnalyzer extends ClassLikeAnalyzer { /** * @var array diff --git a/src/Psalm/Internal/Analyzer/ClassLikeNameOptions.php b/src/Psalm/Internal/Analyzer/ClassLikeNameOptions.php index 60f61a9e87d..9ae064cab5d 100644 --- a/src/Psalm/Internal/Analyzer/ClassLikeNameOptions.php +++ b/src/Psalm/Internal/Analyzer/ClassLikeNameOptions.php @@ -5,7 +5,7 @@ /** * @internal */ -class ClassLikeNameOptions +final class ClassLikeNameOptions { public bool $inferred; diff --git a/src/Psalm/Internal/Analyzer/ClosureAnalyzer.php b/src/Psalm/Internal/Analyzer/ClosureAnalyzer.php index c5daf4f5ea6..9ed72b26914 100644 --- a/src/Psalm/Internal/Analyzer/ClosureAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/ClosureAnalyzer.php @@ -27,7 +27,7 @@ * @internal * @extends FunctionLikeAnalyzer */ -class ClosureAnalyzer extends FunctionLikeAnalyzer +final class ClosureAnalyzer extends FunctionLikeAnalyzer { /** * @param PhpParser\Node\Expr\Closure|PhpParser\Node\Expr\ArrowFunction $function diff --git a/src/Psalm/Internal/Analyzer/CommentAnalyzer.php b/src/Psalm/Internal/Analyzer/CommentAnalyzer.php index 65915d1f34c..ec06f1878fe 100644 --- a/src/Psalm/Internal/Analyzer/CommentAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/CommentAnalyzer.php @@ -41,7 +41,7 @@ /** * @internal */ -class CommentAnalyzer +final class CommentAnalyzer { public const TYPE_REGEX = '(\??\\\?[\(\)A-Za-z0-9_&\<\.=,\>\[\]\-\{\}:|?\\\\]*|\$[a-zA-Z_0-9_]+)'; diff --git a/src/Psalm/Internal/Analyzer/DataFlowNodeData.php b/src/Psalm/Internal/Analyzer/DataFlowNodeData.php index bc4f2dbf533..df96e6fe9a2 100644 --- a/src/Psalm/Internal/Analyzer/DataFlowNodeData.php +++ b/src/Psalm/Internal/Analyzer/DataFlowNodeData.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class DataFlowNodeData +final class DataFlowNodeData { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/Analyzer/FunctionAnalyzer.php b/src/Psalm/Internal/Analyzer/FunctionAnalyzer.php index f22e09cf29f..8aec6258a3c 100644 --- a/src/Psalm/Internal/Analyzer/FunctionAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/FunctionAnalyzer.php @@ -14,7 +14,7 @@ * @internal * @extends FunctionLikeAnalyzer */ -class FunctionAnalyzer extends FunctionLikeAnalyzer +final class FunctionAnalyzer extends FunctionLikeAnalyzer { public function __construct(PhpParser\Node\Stmt\Function_ $function, SourceAnalyzer $source) { diff --git a/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeAnalyzer.php b/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeAnalyzer.php index 15ec85e3938..e13308e5c0f 100644 --- a/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeAnalyzer.php @@ -63,7 +63,7 @@ /** * @internal */ -class ReturnTypeAnalyzer +final class ReturnTypeAnalyzer { /** * @param Closure|Function_|ClassMethod|ArrowFunction $function diff --git a/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeCollector.php b/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeCollector.php index 13280aa1746..2d99b3435af 100644 --- a/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeCollector.php +++ b/src/Psalm/Internal/Analyzer/FunctionLike/ReturnTypeCollector.php @@ -24,7 +24,7 @@ * * @internal */ -class ReturnTypeCollector +final class ReturnTypeCollector { /** * Gets the return types from a list of statements diff --git a/src/Psalm/Internal/Analyzer/InterfaceAnalyzer.php b/src/Psalm/Internal/Analyzer/InterfaceAnalyzer.php index c1f8ed6b4e5..a1a10ebe46b 100644 --- a/src/Psalm/Internal/Analyzer/InterfaceAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/InterfaceAnalyzer.php @@ -25,7 +25,7 @@ /** * @internal */ -class InterfaceAnalyzer extends ClassLikeAnalyzer +final class InterfaceAnalyzer extends ClassLikeAnalyzer { public function __construct( PhpParser\Node\Stmt\Interface_ $interface, diff --git a/src/Psalm/Internal/Analyzer/IssueData.php b/src/Psalm/Internal/Analyzer/IssueData.php index 72e72b21b7c..3bfb9a414cc 100644 --- a/src/Psalm/Internal/Analyzer/IssueData.php +++ b/src/Psalm/Internal/Analyzer/IssueData.php @@ -9,7 +9,7 @@ /** * @internal */ -class IssueData +final class IssueData { public const SEVERITY_INFO = 'info'; public const SEVERITY_ERROR = 'error'; diff --git a/src/Psalm/Internal/Analyzer/MethodAnalyzer.php b/src/Psalm/Internal/Analyzer/MethodAnalyzer.php index 89af7aaec71..bc42192496a 100644 --- a/src/Psalm/Internal/Analyzer/MethodAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/MethodAnalyzer.php @@ -27,7 +27,7 @@ * @internal * @extends FunctionLikeAnalyzer */ -class MethodAnalyzer extends FunctionLikeAnalyzer +final class MethodAnalyzer extends FunctionLikeAnalyzer { // https://github.com/php/php-src/blob/a83923044c48982c80804ae1b45e761c271966d3/Zend/zend_enum.c#L77-L95 private const FORBIDDEN_ENUM_METHODS = [ diff --git a/src/Psalm/Internal/Analyzer/MethodComparator.php b/src/Psalm/Internal/Analyzer/MethodComparator.php index d595df15803..3bfd4de65e9 100644 --- a/src/Psalm/Internal/Analyzer/MethodComparator.php +++ b/src/Psalm/Internal/Analyzer/MethodComparator.php @@ -44,7 +44,7 @@ /** * @internal */ -class MethodComparator +final class MethodComparator { /** * @param string[] $suppressed_issues diff --git a/src/Psalm/Internal/Analyzer/NamespaceAnalyzer.php b/src/Psalm/Internal/Analyzer/NamespaceAnalyzer.php index a01318a3e81..d5f2ac9e4a7 100644 --- a/src/Psalm/Internal/Analyzer/NamespaceAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/NamespaceAnalyzer.php @@ -23,7 +23,7 @@ /** * @internal */ -class NamespaceAnalyzer extends SourceAnalyzer +final class NamespaceAnalyzer extends SourceAnalyzer { use CanAlias; diff --git a/src/Psalm/Internal/Analyzer/ProjectAnalyzer.php b/src/Psalm/Internal/Analyzer/ProjectAnalyzer.php index 6be055ea43b..1a152c1c931 100644 --- a/src/Psalm/Internal/Analyzer/ProjectAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/ProjectAnalyzer.php @@ -97,7 +97,7 @@ /** * @internal */ -class ProjectAnalyzer +final class ProjectAnalyzer { /** * Cached config diff --git a/src/Psalm/Internal/Analyzer/ScopeAnalyzer.php b/src/Psalm/Internal/Analyzer/ScopeAnalyzer.php index 4b8946623b5..808010d09bc 100644 --- a/src/Psalm/Internal/Analyzer/ScopeAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/ScopeAnalyzer.php @@ -17,7 +17,7 @@ /** * @internal */ -class ScopeAnalyzer +final class ScopeAnalyzer { public const ACTION_END = 'END'; public const ACTION_BREAK = 'BREAK'; diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/DoAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/DoAnalyzer.php index 228f0b9e05e..234f8bab45e 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/DoAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/DoAnalyzer.php @@ -28,7 +28,7 @@ /** * @internal */ -class DoAnalyzer +final class DoAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/ForAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/ForAnalyzer.php index 4c0dd4ee16f..dbad2cd129a 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/ForAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/ForAnalyzer.php @@ -19,7 +19,7 @@ /** * @internal */ -class ForAnalyzer +final class ForAnalyzer { /** * @return false|null diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/ForeachAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/ForeachAnalyzer.php index 128eaada6ef..8f0ec8a713f 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/ForeachAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/ForeachAnalyzer.php @@ -74,7 +74,7 @@ /** * @internal */ -class ForeachAnalyzer +final class ForeachAnalyzer { /** * @return false|null diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/IfConditionalAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/IfConditionalAnalyzer.php index e1c5e5e4024..a306cca4ca0 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/IfConditionalAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/IfConditionalAnalyzer.php @@ -29,7 +29,7 @@ /** * @internal */ -class IfConditionalAnalyzer +final class IfConditionalAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/ElseAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/ElseAnalyzer.php index 31fca6dc0f7..f1d9e5a9fd0 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/ElseAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/ElseAnalyzer.php @@ -26,7 +26,7 @@ /** * @internal */ -class ElseAnalyzer +final class ElseAnalyzer { /** * @return false|null diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/ElseIfAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/ElseIfAnalyzer.php index f55d1d0a63e..00c7895c2be 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/ElseIfAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/ElseIfAnalyzer.php @@ -40,7 +40,7 @@ /** * @internal */ -class ElseIfAnalyzer +final class ElseIfAnalyzer { /** * @return false|null diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/IfAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/IfAnalyzer.php index dd2e0989402..ad95cce30d5 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/IfAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/IfElse/IfAnalyzer.php @@ -46,7 +46,7 @@ /** * @internal */ -class IfAnalyzer +final class IfAnalyzer { /** * @param array $pre_assignment_else_redefined_vars diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/IfElseAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/IfElseAnalyzer.php index a5a006a0b31..b4648cd59f2 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/IfElseAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/IfElseAnalyzer.php @@ -41,7 +41,7 @@ /** * @internal */ -class IfElseAnalyzer +final class IfElseAnalyzer { /** * System of type substitution and deletion diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/LoopAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/LoopAnalyzer.php index f1f5ad61fca..f925f961336 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/LoopAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/LoopAnalyzer.php @@ -28,7 +28,7 @@ /** * @internal */ -class LoopAnalyzer +final class LoopAnalyzer { /** * Checks an array of statements in a loop diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/SwitchAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/SwitchAnalyzer.php index a0d9d48200c..73240624c8e 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/SwitchAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/SwitchAnalyzer.php @@ -21,7 +21,7 @@ /** * @internal */ -class SwitchAnalyzer +final class SwitchAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/SwitchCaseAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/SwitchCaseAnalyzer.php index e116f1173f7..54b7e7f3f01 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/SwitchCaseAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/SwitchCaseAnalyzer.php @@ -53,7 +53,7 @@ /** * @internal */ -class SwitchCaseAnalyzer +final class SwitchCaseAnalyzer { /** * @return null|false diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/TryAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/TryAnalyzer.php index 18536b49394..c366f7c612c 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/TryAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/TryAnalyzer.php @@ -32,7 +32,7 @@ /** * @internal */ -class TryAnalyzer +final class TryAnalyzer { /** * @return false|null diff --git a/src/Psalm/Internal/Analyzer/Statements/Block/WhileAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Block/WhileAnalyzer.php index bb486123431..6eea413c4ce 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Block/WhileAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Block/WhileAnalyzer.php @@ -16,7 +16,7 @@ /** * @internal */ -class WhileAnalyzer +final class WhileAnalyzer { /** * @return false|null diff --git a/src/Psalm/Internal/Analyzer/Statements/BreakAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/BreakAnalyzer.php index cbf9be6c0ea..e1b7ff72024 100644 --- a/src/Psalm/Internal/Analyzer/Statements/BreakAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/BreakAnalyzer.php @@ -13,7 +13,7 @@ /** * @internal */ -class BreakAnalyzer +final class BreakAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/ContinueAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/ContinueAnalyzer.php index 9e04d165440..def2aa47287 100644 --- a/src/Psalm/Internal/Analyzer/Statements/ContinueAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/ContinueAnalyzer.php @@ -16,7 +16,7 @@ /** * @internal */ -class ContinueAnalyzer +final class ContinueAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/EchoAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/EchoAnalyzer.php index 300b8fe02aa..b21ae4647c5 100644 --- a/src/Psalm/Internal/Analyzer/Statements/EchoAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/EchoAnalyzer.php @@ -21,7 +21,7 @@ /** * @internal */ -class EchoAnalyzer +final class EchoAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayAnalyzer.php index fa1fb7f1248..3c1034df2db 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayAnalyzer.php @@ -53,7 +53,7 @@ /** * @internal */ -class ArrayAnalyzer +final class ArrayAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayCreationInfo.php b/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayCreationInfo.php index 43161d22f3b..35b2161683e 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayCreationInfo.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/ArrayCreationInfo.php @@ -9,7 +9,7 @@ /** * @internal */ -class ArrayCreationInfo +final class ArrayCreationInfo { /** * @var list diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/AssertionFinder.php b/src/Psalm/Internal/Analyzer/Statements/Expression/AssertionFinder.php index fc57f2177c7..de4d2022aaa 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/AssertionFinder.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/AssertionFinder.php @@ -120,7 +120,7 @@ * For example if $a is an int, if($a > 0) will be turned into an assertion to make psalm understand that in the * if block, $a is a positive-int */ -class AssertionFinder +final class AssertionFinder { public const ASSIGNMENT_TO_RIGHT = 1; public const ASSIGNMENT_TO_LEFT = -1; diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/ArrayAssignmentAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/ArrayAssignmentAnalyzer.php index c071a741181..f00d81a48dd 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/ArrayAssignmentAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/ArrayAssignmentAnalyzer.php @@ -55,7 +55,7 @@ /** * @internal */ -class ArrayAssignmentAnalyzer +final class ArrayAssignmentAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/AssignedProperty.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/AssignedProperty.php index a49249992b5..828c9181b7f 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/AssignedProperty.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/AssignedProperty.php @@ -7,7 +7,7 @@ /** * @internal */ -class AssignedProperty +final class AssignedProperty { public Union $property_type; diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/InstancePropertyAssignmentAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/InstancePropertyAssignmentAnalyzer.php index 127bab853f6..bedec945c25 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/InstancePropertyAssignmentAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/InstancePropertyAssignmentAnalyzer.php @@ -87,7 +87,7 @@ /** * @internal */ -class InstancePropertyAssignmentAnalyzer +final class InstancePropertyAssignmentAnalyzer { /** * @param PropertyFetch|PropertyProperty $stmt diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/StaticPropertyAssignmentAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/StaticPropertyAssignmentAnalyzer.php index e307f514644..cff735cd273 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/StaticPropertyAssignmentAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Assignment/StaticPropertyAssignmentAnalyzer.php @@ -33,7 +33,7 @@ /** * @internal */ -class StaticPropertyAssignmentAnalyzer +final class StaticPropertyAssignmentAnalyzer { /** * @return false|null diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/AssignmentAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/AssignmentAnalyzer.php index c59a554d9ab..debb27e87b7 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/AssignmentAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/AssignmentAnalyzer.php @@ -97,7 +97,7 @@ /** * @internal */ -class AssignmentAnalyzer +final class AssignmentAnalyzer { /** * @param PhpParser\Node\Expr|null $assign_value This has to be null to support list destructuring diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/AndAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/AndAnalyzer.php index 1f5f90309e6..d721f481587 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/AndAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/AndAnalyzer.php @@ -28,7 +28,7 @@ /** * @internal */ -class AndAnalyzer +final class AndAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ArithmeticOpAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ArithmeticOpAnalyzer.php index 4e2b30f63b4..f4ec365b722 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ArithmeticOpAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ArithmeticOpAnalyzer.php @@ -58,7 +58,7 @@ /** * @internal */ -class ArithmeticOpAnalyzer +final class ArithmeticOpAnalyzer { public static function analyze( ?StatementsSource $statements_source, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/CoalesceAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/CoalesceAnalyzer.php index 8a0eed58346..0a52166699a 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/CoalesceAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/CoalesceAnalyzer.php @@ -18,7 +18,7 @@ /** * @internal */ -class CoalesceAnalyzer +final class CoalesceAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ConcatAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ConcatAnalyzer.php index b90ffbc387d..fd7ab531f3e 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ConcatAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/ConcatAnalyzer.php @@ -50,7 +50,7 @@ /** * @internal */ -class ConcatAnalyzer +final class ConcatAnalyzer { private const MAX_LITERALS = 64; diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/NonComparisonOpAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/NonComparisonOpAnalyzer.php index 7f3e7f5391f..63bff0ed888 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/NonComparisonOpAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/NonComparisonOpAnalyzer.php @@ -14,7 +14,7 @@ /** * @internal */ -class NonComparisonOpAnalyzer +final class NonComparisonOpAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/OrAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/OrAnalyzer.php index d315e36f900..2a2e0cf8217 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/OrAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOp/OrAnalyzer.php @@ -36,7 +36,7 @@ /** * @internal */ -class OrAnalyzer +final class OrAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOpAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOpAnalyzer.php index bc799edd290..309d1b8d537 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOpAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/BinaryOpAnalyzer.php @@ -39,7 +39,7 @@ /** * @internal */ -class BinaryOpAnalyzer +final class BinaryOpAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/BitwiseNotAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/BitwiseNotAnalyzer.php index 3efa5c6ce69..e9b16763e37 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/BitwiseNotAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/BitwiseNotAnalyzer.php @@ -24,7 +24,7 @@ /** * @internal */ -class BitwiseNotAnalyzer +final class BitwiseNotAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/BooleanNotAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/BooleanNotAnalyzer.php index fa053702791..3c75dd9efca 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/BooleanNotAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/BooleanNotAnalyzer.php @@ -15,7 +15,7 @@ /** * @internal */ -class BooleanNotAnalyzer +final class BooleanNotAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentAnalyzer.php index 2d8380ceb69..cd3e590b8b0 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentAnalyzer.php @@ -80,7 +80,7 @@ /** * @internal */ -class ArgumentAnalyzer +final class ArgumentAnalyzer { /** * @param array> $class_generic_params diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentMapPopulator.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentMapPopulator.php index fbbc5e24ea6..ac8016e2a20 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentMapPopulator.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentMapPopulator.php @@ -21,7 +21,7 @@ /** * @internal */ -class ArgumentMapPopulator +final class ArgumentMapPopulator { /** * @param MethodCall|StaticCall|FuncCall|New_ $stmt diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentsAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentsAnalyzer.php index d166ed3774c..9ff268abeb6 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentsAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArgumentsAnalyzer.php @@ -67,7 +67,7 @@ /** * @internal */ -class ArgumentsAnalyzer +final class ArgumentsAnalyzer { /** * @param list $args diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArrayFunctionArgumentsAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArrayFunctionArgumentsAnalyzer.php index c1aa8540e1a..55364514eb9 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArrayFunctionArgumentsAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ArrayFunctionArgumentsAnalyzer.php @@ -57,7 +57,7 @@ /** * @internal */ -class ArrayFunctionArgumentsAnalyzer +final class ArrayFunctionArgumentsAnalyzer { /** * @param array $args diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ClassTemplateParamCollector.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ClassTemplateParamCollector.php index c3bbd2995b7..367f2d26d27 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ClassTemplateParamCollector.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/ClassTemplateParamCollector.php @@ -21,7 +21,7 @@ /** * @internal */ -class ClassTemplateParamCollector +final class ClassTemplateParamCollector { /** * @param lowercase-string $method_name diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallAnalyzer.php index 21bdf3f9ea7..3c44bad7067 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallAnalyzer.php @@ -78,7 +78,7 @@ /** * @internal */ -class FunctionCallAnalyzer extends CallAnalyzer +final class FunctionCallAnalyzer extends CallAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallInfo.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallInfo.php index c2e38864d5b..9bcec9ed740 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallInfo.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallInfo.php @@ -10,7 +10,7 @@ /** * @internal */ -class FunctionCallInfo +final class FunctionCallInfo { public ?string $function_id = null; diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallReturnTypeFetcher.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallReturnTypeFetcher.php index 34dae01f345..e15fd22a71d 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallReturnTypeFetcher.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/FunctionCallReturnTypeFetcher.php @@ -55,7 +55,7 @@ /** * @internal */ -class FunctionCallReturnTypeFetcher +final class FunctionCallReturnTypeFetcher { /** * @param non-empty-string $function_id diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicCallContext.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicCallContext.php index 7e033b36f1d..04da740e01c 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicCallContext.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicCallContext.php @@ -8,7 +8,7 @@ /** * @internal */ -class AtomicCallContext +final class AtomicCallContext { public MethodIdentifier $method_id; diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicMethodCallAnalysisResult.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicMethodCallAnalysisResult.php index 94703207fc6..a4e6d2153fb 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicMethodCallAnalysisResult.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicMethodCallAnalysisResult.php @@ -8,7 +8,7 @@ /** * @internal */ -class AtomicMethodCallAnalysisResult +final class AtomicMethodCallAnalysisResult { public ?Union $return_type = null; diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicMethodCallAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicMethodCallAnalyzer.php index 5997ac82efa..62903d0af76 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicMethodCallAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/AtomicMethodCallAnalyzer.php @@ -62,7 +62,7 @@ * * @internal */ -class AtomicMethodCallAnalyzer extends CallAnalyzer +final class AtomicMethodCallAnalyzer extends CallAnalyzer { /** * @param TNamedObject|TTemplateParam|null $static_type diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/ExistingAtomicMethodCallAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/ExistingAtomicMethodCallAnalyzer.php index 05210818b64..bf8d1af4239 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/ExistingAtomicMethodCallAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/ExistingAtomicMethodCallAnalyzer.php @@ -55,7 +55,7 @@ /** * @internal */ -class ExistingAtomicMethodCallAnalyzer extends CallAnalyzer +final class ExistingAtomicMethodCallAnalyzer extends CallAnalyzer { /** * @param TNamedObject|TTemplateParam|null $static_type diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallProhibitionAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallProhibitionAnalyzer.php index d3d42a95ef3..782062ea292 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallProhibitionAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallProhibitionAnalyzer.php @@ -15,7 +15,7 @@ /** * @internal */ -class MethodCallProhibitionAnalyzer +final class MethodCallProhibitionAnalyzer { /** * @param string[] $suppressed_issues diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallPurityAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallPurityAnalyzer.php index 760adf93590..a23332ee3ca 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallPurityAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallPurityAnalyzer.php @@ -22,7 +22,7 @@ /** * @internal */ -class MethodCallPurityAnalyzer +final class MethodCallPurityAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallReturnTypeFetcher.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallReturnTypeFetcher.php index a3bd4b3b493..84021ca3651 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallReturnTypeFetcher.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodCallReturnTypeFetcher.php @@ -41,7 +41,7 @@ /** * @internal */ -class MethodCallReturnTypeFetcher +final class MethodCallReturnTypeFetcher { /** * @param TNamedObject|TTemplateParam|null $static_type diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodVisibilityAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodVisibilityAnalyzer.php index 2cc632a35e3..0a81ee8ecac 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodVisibilityAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MethodVisibilityAnalyzer.php @@ -20,7 +20,7 @@ /** * @internal */ -class MethodVisibilityAnalyzer +final class MethodVisibilityAnalyzer { /** * @param string[] $suppressed_issues diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MissingMethodCallHandler.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MissingMethodCallHandler.php index 1f287b98d57..22f483c1bcd 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MissingMethodCallHandler.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/Method/MissingMethodCallHandler.php @@ -32,7 +32,7 @@ /** * @internal */ -class MissingMethodCallHandler +final class MissingMethodCallHandler { public static function handleMagicMethod( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/MethodCallAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/MethodCallAnalyzer.php index 72c343d1073..ab4f1f0428b 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/MethodCallAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/MethodCallAnalyzer.php @@ -41,7 +41,7 @@ /** * @internal */ -class MethodCallAnalyzer extends CallAnalyzer +final class MethodCallAnalyzer extends CallAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NamedFunctionCallHandler.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NamedFunctionCallHandler.php index 874f0618172..961662f7044 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NamedFunctionCallHandler.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NamedFunctionCallHandler.php @@ -56,7 +56,7 @@ /** * @internal */ -class NamedFunctionCallHandler +final class NamedFunctionCallHandler { /** * @param lowercase-string $function_id diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NewAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NewAnalyzer.php index 45476ca22b6..1a9daef9fb5 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NewAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/NewAnalyzer.php @@ -67,7 +67,7 @@ /** * @internal */ -class NewAnalyzer extends CallAnalyzer +final class NewAnalyzer extends CallAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticCallAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticCallAnalyzer.php index 8302dcfca44..a357afac605 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticCallAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticCallAnalyzer.php @@ -36,7 +36,7 @@ /** * @internal */ -class StaticCallAnalyzer extends CallAnalyzer +final class StaticCallAnalyzer extends CallAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticMethod/AtomicStaticCallAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticMethod/AtomicStaticCallAnalyzer.php index b0839345418..e42024d08f6 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticMethod/AtomicStaticCallAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticMethod/AtomicStaticCallAnalyzer.php @@ -66,7 +66,7 @@ /** * @internal */ -class AtomicStaticCallAnalyzer +final class AtomicStaticCallAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticMethod/ExistingAtomicStaticCallAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticMethod/ExistingAtomicStaticCallAnalyzer.php index a8c916534ea..23c0078facd 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticMethod/ExistingAtomicStaticCallAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Call/StaticMethod/ExistingAtomicStaticCallAnalyzer.php @@ -50,7 +50,7 @@ /** * @internal */ -class ExistingAtomicStaticCallAnalyzer +final class ExistingAtomicStaticCallAnalyzer { /** * @param list $args diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/CastAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/CastAnalyzer.php index 99f045d71c6..bbcb0e3105a 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/CastAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/CastAnalyzer.php @@ -58,7 +58,7 @@ /** * @internal */ -class CastAnalyzer +final class CastAnalyzer { /** @var string[] */ private const PSEUDO_CASTABLE_CLASSES = [ diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/ClassConstAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/ClassConstAnalyzer.php index 9335f658324..d9ec74f47bf 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/ClassConstAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/ClassConstAnalyzer.php @@ -56,7 +56,7 @@ /** * @internal */ -class ClassConstAnalyzer +final class ClassConstAnalyzer { /** * @psalm-suppress ComplexMethod to be refactored. We should probably regroup the two big if about $stmt->class and diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/CloneAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/CloneAnalyzer.php index 7f1927951d2..c179d12c142 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/CloneAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/CloneAnalyzer.php @@ -27,7 +27,7 @@ /** * @internal */ -class CloneAnalyzer +final class CloneAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/EmptyAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/EmptyAnalyzer.php index 9728d331397..3b9014f85b4 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/EmptyAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/EmptyAnalyzer.php @@ -14,7 +14,7 @@ /** * @internal */ -class EmptyAnalyzer +final class EmptyAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/EncapsulatedStringAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/EncapsulatedStringAnalyzer.php index 9792a91c87e..563d58b1a58 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/EncapsulatedStringAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/EncapsulatedStringAnalyzer.php @@ -26,7 +26,7 @@ /** * @internal */ -class EncapsulatedStringAnalyzer +final class EncapsulatedStringAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/EvalAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/EvalAnalyzer.php index 34160e58b49..3f6b2a8d19b 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/EvalAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/EvalAnalyzer.php @@ -19,7 +19,7 @@ /** * @internal */ -class EvalAnalyzer +final class EvalAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/ExitAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/ExitAnalyzer.php index 36d6be84b95..fcafecdf3b1 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/ExitAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/ExitAnalyzer.php @@ -24,7 +24,7 @@ /** * @internal */ -class ExitAnalyzer +final class ExitAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/ExpressionIdentifier.php b/src/Psalm/Internal/Analyzer/Statements/Expression/ExpressionIdentifier.php index 53794faa358..00a249ec83b 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/ExpressionIdentifier.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/ExpressionIdentifier.php @@ -17,7 +17,7 @@ /** * @internal */ -class ExpressionIdentifier +final class ExpressionIdentifier { public static function getVarId( PhpParser\Node\Expr $stmt, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ArrayFetchAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ArrayFetchAnalyzer.php index 9830012c3a6..4a3a1f5c903 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ArrayFetchAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ArrayFetchAnalyzer.php @@ -100,7 +100,7 @@ /** * @internal */ -class ArrayFetchAnalyzer +final class ArrayFetchAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/AtomicPropertyFetchAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/AtomicPropertyFetchAnalyzer.php index ff14ed24273..0fdc76b40ce 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/AtomicPropertyFetchAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/AtomicPropertyFetchAnalyzer.php @@ -76,7 +76,7 @@ /** * @internal */ -class AtomicPropertyFetchAnalyzer +final class AtomicPropertyFetchAnalyzer { /** * @param array $invalid_fetch_types $invalid_fetch_types diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ConstFetchAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ConstFetchAnalyzer.php index 8b30a60fc91..db382c4f914 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ConstFetchAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/ConstFetchAnalyzer.php @@ -28,7 +28,7 @@ /** * @internal */ -class ConstFetchAnalyzer +final class ConstFetchAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/InstancePropertyFetchAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/InstancePropertyFetchAnalyzer.php index 528acd0609d..acf004490c1 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/InstancePropertyFetchAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/InstancePropertyFetchAnalyzer.php @@ -33,7 +33,7 @@ /** * @internal */ -class InstancePropertyFetchAnalyzer +final class InstancePropertyFetchAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/StaticPropertyFetchAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/StaticPropertyFetchAnalyzer.php index 35bc7061427..94771ed2e17 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/StaticPropertyFetchAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/StaticPropertyFetchAnalyzer.php @@ -37,7 +37,7 @@ /** * @internal */ -class StaticPropertyFetchAnalyzer +final class StaticPropertyFetchAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/VariableFetchAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/VariableFetchAnalyzer.php index 80ad5e0e97f..324dd7b30b0 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/VariableFetchAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/Fetch/VariableFetchAnalyzer.php @@ -41,7 +41,7 @@ /** * @internal */ -class VariableFetchAnalyzer +final class VariableFetchAnalyzer { public const SUPER_GLOBALS = [ '$GLOBALS', diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/IncDecExpressionAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/IncDecExpressionAnalyzer.php index 1526bb6a59f..83079c98879 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/IncDecExpressionAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/IncDecExpressionAnalyzer.php @@ -20,7 +20,7 @@ /** * @internal */ -class IncDecExpressionAnalyzer +final class IncDecExpressionAnalyzer { /** * @param PostInc|PostDec|PreInc|PreDec $stmt diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/IncludeAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/IncludeAnalyzer.php index e293afabc58..24db2b6d92e 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/IncludeAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/IncludeAnalyzer.php @@ -47,7 +47,7 @@ /** * @internal */ -class IncludeAnalyzer +final class IncludeAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/InstanceofAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/InstanceofAnalyzer.php index 83b04cd9478..6e036490587 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/InstanceofAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/InstanceofAnalyzer.php @@ -17,7 +17,7 @@ /** * @internal */ -class InstanceofAnalyzer +final class InstanceofAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/IssetAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/IssetAnalyzer.php index a9db2fead9e..6303733642b 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/IssetAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/IssetAnalyzer.php @@ -14,7 +14,7 @@ /** * @internal */ -class IssetAnalyzer +final class IssetAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/MagicConstAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/MagicConstAnalyzer.php index 129266f95d2..379e3e75bf5 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/MagicConstAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/MagicConstAnalyzer.php @@ -21,7 +21,7 @@ /** * @internal */ -class MagicConstAnalyzer +final class MagicConstAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/MatchAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/MatchAnalyzer.php index a76a199089a..ffaa0f5b387 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/MatchAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/MatchAnalyzer.php @@ -44,7 +44,7 @@ /** * @internal */ -class MatchAnalyzer +final class MatchAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/NullsafeAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/NullsafeAnalyzer.php index 739bb5b7ba2..129c5326d16 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/NullsafeAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/NullsafeAnalyzer.php @@ -18,7 +18,7 @@ /** * @internal */ -class NullsafeAnalyzer +final class NullsafeAnalyzer { /** * @param PhpParser\Node\Expr\NullsafePropertyFetch|PhpParser\Node\Expr\NullsafeMethodCall $stmt diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/PrintAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/PrintAnalyzer.php index 64cebbc80d4..3d1bd13fad1 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/PrintAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/PrintAnalyzer.php @@ -21,7 +21,7 @@ /** * @internal */ -class PrintAnalyzer +final class PrintAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/SimpleTypeInferer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/SimpleTypeInferer.php index 6d94391ffd2..d35231e4102 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/SimpleTypeInferer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/SimpleTypeInferer.php @@ -45,7 +45,7 @@ * * @internal */ -class SimpleTypeInferer +final class SimpleTypeInferer { /** * @param ?array $existing_class_constants diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/TernaryAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/TernaryAnalyzer.php index 7d990eaf1dd..7524c523baa 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/TernaryAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/TernaryAnalyzer.php @@ -38,7 +38,7 @@ /** * @internal */ -class TernaryAnalyzer +final class TernaryAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/UnaryPlusMinusAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/UnaryPlusMinusAnalyzer.php index eb4f256f444..eec166064d2 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/UnaryPlusMinusAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/UnaryPlusMinusAnalyzer.php @@ -25,7 +25,7 @@ /** * @internal */ -class UnaryPlusMinusAnalyzer +final class UnaryPlusMinusAnalyzer { /** * @param PhpParser\Node\Expr\UnaryMinus|PhpParser\Node\Expr\UnaryPlus $stmt diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/YieldAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/YieldAnalyzer.php index d5e6174b230..a34deaedfbb 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/YieldAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/YieldAnalyzer.php @@ -28,7 +28,7 @@ /** * @internal */ -class YieldAnalyzer +final class YieldAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/Expression/YieldFromAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/Expression/YieldFromAnalyzer.php index 03f63c637f3..d77e1936c99 100644 --- a/src/Psalm/Internal/Analyzer/Statements/Expression/YieldFromAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/Expression/YieldFromAnalyzer.php @@ -17,7 +17,7 @@ /** * @internal */ -class YieldFromAnalyzer +final class YieldFromAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/ExpressionAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/ExpressionAnalyzer.php index 7cdb1b54a05..277787b3ef7 100644 --- a/src/Psalm/Internal/Analyzer/Statements/ExpressionAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/ExpressionAnalyzer.php @@ -65,7 +65,7 @@ /** * @internal */ -class ExpressionAnalyzer +final class ExpressionAnalyzer { /** * @param bool $assigned_to_reference This is set to true when the expression being analyzed diff --git a/src/Psalm/Internal/Analyzer/Statements/GlobalAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/GlobalAnalyzer.php index 4eb29ca7b62..d7ec4dcf4b0 100644 --- a/src/Psalm/Internal/Analyzer/Statements/GlobalAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/GlobalAnalyzer.php @@ -19,7 +19,7 @@ /** * @internal */ -class GlobalAnalyzer +final class GlobalAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/ReturnAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/ReturnAnalyzer.php index 2ea1e981544..4f0867f169d 100644 --- a/src/Psalm/Internal/Analyzer/Statements/ReturnAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/ReturnAnalyzer.php @@ -52,7 +52,7 @@ /** * @internal */ -class ReturnAnalyzer +final class ReturnAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/StaticAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/StaticAnalyzer.php index eecb5b84284..9ade50098f6 100644 --- a/src/Psalm/Internal/Analyzer/Statements/StaticAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/StaticAnalyzer.php @@ -19,7 +19,7 @@ /** * @internal */ -class StaticAnalyzer +final class StaticAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/ThrowAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/ThrowAnalyzer.php index c0d1b0b2a45..6ae148f8b9e 100644 --- a/src/Psalm/Internal/Analyzer/Statements/ThrowAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/ThrowAnalyzer.php @@ -16,7 +16,7 @@ /** * @internal */ -class ThrowAnalyzer +final class ThrowAnalyzer { /** * @param PhpParser\Node\Stmt\Throw_|PhpParser\Node\Expr\Throw_ $stmt diff --git a/src/Psalm/Internal/Analyzer/Statements/UnsetAnalyzer.php b/src/Psalm/Internal/Analyzer/Statements/UnsetAnalyzer.php index b1c12d12cd4..e93b58b6329 100644 --- a/src/Psalm/Internal/Analyzer/Statements/UnsetAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/Statements/UnsetAnalyzer.php @@ -24,7 +24,7 @@ /** * @internal */ -class UnsetAnalyzer +final class UnsetAnalyzer { public static function analyze( StatementsAnalyzer $statements_analyzer, diff --git a/src/Psalm/Internal/Analyzer/Statements/UnusedAssignmentRemover.php b/src/Psalm/Internal/Analyzer/Statements/UnusedAssignmentRemover.php index 188ad00bb3c..d3aaa7050a7 100644 --- a/src/Psalm/Internal/Analyzer/Statements/UnusedAssignmentRemover.php +++ b/src/Psalm/Internal/Analyzer/Statements/UnusedAssignmentRemover.php @@ -22,7 +22,7 @@ /** * @internal */ -class UnusedAssignmentRemover +final class UnusedAssignmentRemover { /** * @var array diff --git a/src/Psalm/Internal/Analyzer/StatementsAnalyzer.php b/src/Psalm/Internal/Analyzer/StatementsAnalyzer.php index fc75e1631eb..cb3c9b49d94 100644 --- a/src/Psalm/Internal/Analyzer/StatementsAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/StatementsAnalyzer.php @@ -93,7 +93,7 @@ /** * @internal */ -class StatementsAnalyzer extends SourceAnalyzer +final class StatementsAnalyzer extends SourceAnalyzer { protected SourceAnalyzer $source; diff --git a/src/Psalm/Internal/Analyzer/TraitAnalyzer.php b/src/Psalm/Internal/Analyzer/TraitAnalyzer.php index c6192a666a5..dcb456fd75f 100644 --- a/src/Psalm/Internal/Analyzer/TraitAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/TraitAnalyzer.php @@ -12,7 +12,7 @@ /** * @internal */ -class TraitAnalyzer extends ClassLikeAnalyzer +final class TraitAnalyzer extends ClassLikeAnalyzer { private Aliases $aliases; diff --git a/src/Psalm/Internal/Analyzer/TypeAnalyzer.php b/src/Psalm/Internal/Analyzer/TypeAnalyzer.php index 0c871fe2200..1e13aa83a51 100644 --- a/src/Psalm/Internal/Analyzer/TypeAnalyzer.php +++ b/src/Psalm/Internal/Analyzer/TypeAnalyzer.php @@ -11,7 +11,7 @@ /** * @internal */ -class TypeAnalyzer +final class TypeAnalyzer { /** * Takes two arrays of types and merges them diff --git a/src/Psalm/Internal/Cache.php b/src/Psalm/Internal/Cache.php index 88e2f5704d7..50c838f3b5a 100644 --- a/src/Psalm/Internal/Cache.php +++ b/src/Psalm/Internal/Cache.php @@ -23,7 +23,7 @@ /** * @internal */ -class Cache +final class Cache { private Config $config; diff --git a/src/Psalm/Internal/Clause.php b/src/Psalm/Internal/Clause.php index 31f32bea065..b8a44c939ee 100644 --- a/src/Psalm/Internal/Clause.php +++ b/src/Psalm/Internal/Clause.php @@ -26,7 +26,7 @@ * @internal * @psalm-immutable */ -class Clause +final class Clause { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/Codebase/Analyzer.php b/src/Psalm/Internal/Codebase/Analyzer.php index ba0209ea6f2..72825b05baf 100644 --- a/src/Psalm/Internal/Codebase/Analyzer.php +++ b/src/Psalm/Internal/Codebase/Analyzer.php @@ -95,7 +95,7 @@ * * Called in the analysis phase of Psalm's execution */ -class Analyzer +final class Analyzer { private Config $config; diff --git a/src/Psalm/Internal/Codebase/ClassLikes.php b/src/Psalm/Internal/Codebase/ClassLikes.php index a7045a43af5..b57bbe076da 100644 --- a/src/Psalm/Internal/Codebase/ClassLikes.php +++ b/src/Psalm/Internal/Codebase/ClassLikes.php @@ -71,7 +71,7 @@ * * Handles information about classes, interfaces and traits */ -class ClassLikes +final class ClassLikes { private ClassLikeStorageProvider $classlike_storage_provider; diff --git a/src/Psalm/Internal/Codebase/ConstantTypeResolver.php b/src/Psalm/Internal/Codebase/ConstantTypeResolver.php index 9bf8cabab2c..866b5180e14 100644 --- a/src/Psalm/Internal/Codebase/ConstantTypeResolver.php +++ b/src/Psalm/Internal/Codebase/ConstantTypeResolver.php @@ -53,7 +53,7 @@ /** * @internal */ -class ConstantTypeResolver +final class ConstantTypeResolver { public static function resolve( ClassLikes $classlikes, diff --git a/src/Psalm/Internal/Codebase/Functions.php b/src/Psalm/Internal/Codebase/Functions.php index 5e24f071313..acba38f28bb 100644 --- a/src/Psalm/Internal/Codebase/Functions.php +++ b/src/Psalm/Internal/Codebase/Functions.php @@ -35,7 +35,7 @@ /** * @internal */ -class Functions +final class Functions { private FileStorageProvider $file_storage_provider; diff --git a/src/Psalm/Internal/Codebase/InternalCallMapHandler.php b/src/Psalm/Internal/Codebase/InternalCallMapHandler.php index 71ce092eae9..e5c96b624ed 100644 --- a/src/Psalm/Internal/Codebase/InternalCallMapHandler.php +++ b/src/Psalm/Internal/Codebase/InternalCallMapHandler.php @@ -33,7 +33,7 @@ * * Gets values from the call map array, which stores data about native functions and methods */ -class InternalCallMapHandler +final class InternalCallMapHandler { private const PHP_MAJOR_VERSION = 8; private const PHP_MINOR_VERSION = 3; diff --git a/src/Psalm/Internal/Codebase/Methods.php b/src/Psalm/Internal/Codebase/Methods.php index 2d276bf2f24..9648729c473 100644 --- a/src/Psalm/Internal/Codebase/Methods.php +++ b/src/Psalm/Internal/Codebase/Methods.php @@ -53,7 +53,7 @@ * * Handles information about class methods */ -class Methods +final class Methods { private ClassLikeStorageProvider $classlike_storage_provider; diff --git a/src/Psalm/Internal/Codebase/Populator.php b/src/Psalm/Internal/Codebase/Populator.php index 69aa208044e..6c6dc25b187 100644 --- a/src/Psalm/Internal/Codebase/Populator.php +++ b/src/Psalm/Internal/Codebase/Populator.php @@ -42,7 +42,7 @@ * * Populates file and class information so that analysis can work properly */ -class Populator +final class Populator { private ClassLikeStorageProvider $classlike_storage_provider; diff --git a/src/Psalm/Internal/Codebase/Properties.php b/src/Psalm/Internal/Codebase/Properties.php index ac7c8add999..9dad3906fc2 100644 --- a/src/Psalm/Internal/Codebase/Properties.php +++ b/src/Psalm/Internal/Codebase/Properties.php @@ -23,7 +23,7 @@ * * Handles information about class properties */ -class Properties +final class Properties { private ClassLikeStorageProvider $classlike_storage_provider; diff --git a/src/Psalm/Internal/Codebase/PropertyMap.php b/src/Psalm/Internal/Codebase/PropertyMap.php index d66c58c4579..36e9da02d6b 100644 --- a/src/Psalm/Internal/Codebase/PropertyMap.php +++ b/src/Psalm/Internal/Codebase/PropertyMap.php @@ -8,7 +8,7 @@ /** * @internal */ -class PropertyMap +final class PropertyMap { /** * @var array>|null diff --git a/src/Psalm/Internal/Codebase/ReferenceMapGenerator.php b/src/Psalm/Internal/Codebase/ReferenceMapGenerator.php index 1421846bc1d..73d3918824d 100644 --- a/src/Psalm/Internal/Codebase/ReferenceMapGenerator.php +++ b/src/Psalm/Internal/Codebase/ReferenceMapGenerator.php @@ -7,7 +7,7 @@ /** * @internal */ -class ReferenceMapGenerator +final class ReferenceMapGenerator { /** * @return array diff --git a/src/Psalm/Internal/Codebase/Reflection.php b/src/Psalm/Internal/Codebase/Reflection.php index f62cfdc7e28..6ab8e4af59d 100644 --- a/src/Psalm/Internal/Codebase/Reflection.php +++ b/src/Psalm/Internal/Codebase/Reflection.php @@ -37,7 +37,7 @@ * * Handles information gleaned from class and function reflection */ -class Reflection +final class Reflection { private ClassLikeStorageProvider $storage_provider; diff --git a/src/Psalm/Internal/Codebase/Scanner.php b/src/Psalm/Internal/Codebase/Scanner.php index ab2c586ef72..c30d6c5a022 100644 --- a/src/Psalm/Internal/Codebase/Scanner.php +++ b/src/Psalm/Internal/Codebase/Scanner.php @@ -83,7 +83,7 @@ * * Contains methods that aid in the scanning of Psalm's codebase */ -class Scanner +final class Scanner { private Codebase $codebase; diff --git a/src/Psalm/Internal/Codebase/TaintFlowGraph.php b/src/Psalm/Internal/Codebase/TaintFlowGraph.php index b18b82eb161..bb7cd993879 100644 --- a/src/Psalm/Internal/Codebase/TaintFlowGraph.php +++ b/src/Psalm/Internal/Codebase/TaintFlowGraph.php @@ -46,7 +46,7 @@ /** * @internal */ -class TaintFlowGraph extends DataFlowGraph +final class TaintFlowGraph extends DataFlowGraph { /** @var array */ private array $sources = []; diff --git a/src/Psalm/Internal/Codebase/VariableUseGraph.php b/src/Psalm/Internal/Codebase/VariableUseGraph.php index 22069bca81f..d90b2878c00 100644 --- a/src/Psalm/Internal/Codebase/VariableUseGraph.php +++ b/src/Psalm/Internal/Codebase/VariableUseGraph.php @@ -13,7 +13,7 @@ /** * @internal */ -class VariableUseGraph extends DataFlowGraph +final class VariableUseGraph extends DataFlowGraph { /** @var array> */ protected array $backward_edges = []; diff --git a/src/Psalm/Internal/DataFlow/Path.php b/src/Psalm/Internal/DataFlow/Path.php index a6de16c95ee..c6c0e279761 100644 --- a/src/Psalm/Internal/DataFlow/Path.php +++ b/src/Psalm/Internal/DataFlow/Path.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class Path +final class Path { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/DataFlow/TaintSink.php b/src/Psalm/Internal/DataFlow/TaintSink.php index 2d89b628d3c..997b63b97c8 100644 --- a/src/Psalm/Internal/DataFlow/TaintSink.php +++ b/src/Psalm/Internal/DataFlow/TaintSink.php @@ -5,6 +5,6 @@ /** * @internal */ -class TaintSink extends DataFlowNode +final class TaintSink extends DataFlowNode { } diff --git a/src/Psalm/Internal/DataFlow/TaintSource.php b/src/Psalm/Internal/DataFlow/TaintSource.php index 747155f7bcb..1777afe99f7 100644 --- a/src/Psalm/Internal/DataFlow/TaintSource.php +++ b/src/Psalm/Internal/DataFlow/TaintSource.php @@ -5,6 +5,6 @@ /** * @internal */ -class TaintSource extends DataFlowNode +final class TaintSource extends DataFlowNode { } diff --git a/src/Psalm/Internal/Diff/ClassStatementsDiffer.php b/src/Psalm/Internal/Diff/ClassStatementsDiffer.php index 65cccb3e60c..235cff8f400 100644 --- a/src/Psalm/Internal/Diff/ClassStatementsDiffer.php +++ b/src/Psalm/Internal/Diff/ClassStatementsDiffer.php @@ -16,7 +16,7 @@ /** * @internal */ -class ClassStatementsDiffer extends AstDiffer +final class ClassStatementsDiffer extends AstDiffer { /** * Calculate diff (edit script) from $a to $b. diff --git a/src/Psalm/Internal/Diff/DiffElem.php b/src/Psalm/Internal/Diff/DiffElem.php index b76caab99f9..e64a56cce0d 100644 --- a/src/Psalm/Internal/Diff/DiffElem.php +++ b/src/Psalm/Internal/Diff/DiffElem.php @@ -10,7 +10,7 @@ * @internal * @psalm-immutable */ -class DiffElem +final class DiffElem { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/Diff/FileDiffer.php b/src/Psalm/Internal/Diff/FileDiffer.php index 668c6456bc5..801dae66173 100644 --- a/src/Psalm/Internal/Diff/FileDiffer.php +++ b/src/Psalm/Internal/Diff/FileDiffer.php @@ -23,7 +23,7 @@ * * @internal */ -class FileDiffer +final class FileDiffer { /** * @param list $a diff --git a/src/Psalm/Internal/Diff/FileStatementsDiffer.php b/src/Psalm/Internal/Diff/FileStatementsDiffer.php index 1fb58c710c5..f8197fc12c3 100644 --- a/src/Psalm/Internal/Diff/FileStatementsDiffer.php +++ b/src/Psalm/Internal/Diff/FileStatementsDiffer.php @@ -11,7 +11,7 @@ /** * @internal */ -class FileStatementsDiffer extends AstDiffer +final class FileStatementsDiffer extends AstDiffer { /** * Calculate diff (edit script) from $a to $b. diff --git a/src/Psalm/Internal/Diff/NamespaceStatementsDiffer.php b/src/Psalm/Internal/Diff/NamespaceStatementsDiffer.php index cfeab6123e2..b8ea37c5e16 100644 --- a/src/Psalm/Internal/Diff/NamespaceStatementsDiffer.php +++ b/src/Psalm/Internal/Diff/NamespaceStatementsDiffer.php @@ -11,7 +11,7 @@ /** * @internal */ -class NamespaceStatementsDiffer extends AstDiffer +final class NamespaceStatementsDiffer extends AstDiffer { /** * Calculate diff (edit script) from $a to $b. diff --git a/src/Psalm/Internal/EventDispatcher.php b/src/Psalm/Internal/EventDispatcher.php index fb574949ea1..989e8ec1f3b 100644 --- a/src/Psalm/Internal/EventDispatcher.php +++ b/src/Psalm/Internal/EventDispatcher.php @@ -48,7 +48,7 @@ /** * @internal */ -class EventDispatcher +final class EventDispatcher { /** * Static methods to be called after method checks have completed diff --git a/src/Psalm/Internal/ExecutionEnvironment/BuildInfoCollector.php b/src/Psalm/Internal/ExecutionEnvironment/BuildInfoCollector.php index 30a96bae428..e2c4ae99cf6 100644 --- a/src/Psalm/Internal/ExecutionEnvironment/BuildInfoCollector.php +++ b/src/Psalm/Internal/ExecutionEnvironment/BuildInfoCollector.php @@ -20,7 +20,7 @@ * @author Kitamura Satoshi * @internal */ -class BuildInfoCollector +final class BuildInfoCollector { /** * Environment variables. diff --git a/src/Psalm/Internal/ExecutionEnvironment/GitInfoCollector.php b/src/Psalm/Internal/ExecutionEnvironment/GitInfoCollector.php index d9ec447db52..2330062120e 100644 --- a/src/Psalm/Internal/ExecutionEnvironment/GitInfoCollector.php +++ b/src/Psalm/Internal/ExecutionEnvironment/GitInfoCollector.php @@ -21,7 +21,7 @@ * @author Kitamura Satoshi * @internal */ -class GitInfoCollector +final class GitInfoCollector { /** * Git command. diff --git a/src/Psalm/Internal/FileManipulation/ClassDocblockManipulator.php b/src/Psalm/Internal/FileManipulation/ClassDocblockManipulator.php index 53b6509344b..fd1445402cf 100644 --- a/src/Psalm/Internal/FileManipulation/ClassDocblockManipulator.php +++ b/src/Psalm/Internal/FileManipulation/ClassDocblockManipulator.php @@ -17,7 +17,7 @@ /** * @internal */ -class ClassDocblockManipulator +final class ClassDocblockManipulator { /** * @var array> diff --git a/src/Psalm/Internal/FileManipulation/CodeMigration.php b/src/Psalm/Internal/FileManipulation/CodeMigration.php index 641e6aaf5d1..e118e195e72 100644 --- a/src/Psalm/Internal/FileManipulation/CodeMigration.php +++ b/src/Psalm/Internal/FileManipulation/CodeMigration.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class CodeMigration +final class CodeMigration { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/FileManipulation/FileManipulationBuffer.php b/src/Psalm/Internal/FileManipulation/FileManipulationBuffer.php index 7bd147c06ec..7c5870b65c1 100644 --- a/src/Psalm/Internal/FileManipulation/FileManipulationBuffer.php +++ b/src/Psalm/Internal/FileManipulation/FileManipulationBuffer.php @@ -19,7 +19,7 @@ /** * @internal */ -class FileManipulationBuffer +final class FileManipulationBuffer { /** @var array */ private static array $file_manipulations = []; diff --git a/src/Psalm/Internal/FileManipulation/FunctionDocblockManipulator.php b/src/Psalm/Internal/FileManipulation/FunctionDocblockManipulator.php index f10a42379e2..85ad399f583 100644 --- a/src/Psalm/Internal/FileManipulation/FunctionDocblockManipulator.php +++ b/src/Psalm/Internal/FileManipulation/FunctionDocblockManipulator.php @@ -34,7 +34,7 @@ /** * @internal */ -class FunctionDocblockManipulator +final class FunctionDocblockManipulator { /** * Manipulators ordered by line number diff --git a/src/Psalm/Internal/FileManipulation/PropertyDocblockManipulator.php b/src/Psalm/Internal/FileManipulation/PropertyDocblockManipulator.php index 3894e4edf81..8e25959cff6 100644 --- a/src/Psalm/Internal/FileManipulation/PropertyDocblockManipulator.php +++ b/src/Psalm/Internal/FileManipulation/PropertyDocblockManipulator.php @@ -22,7 +22,7 @@ /** * @internal */ -class PropertyDocblockManipulator +final class PropertyDocblockManipulator { /** * @var array> diff --git a/src/Psalm/Internal/Fork/ForkProcessDoneMessage.php b/src/Psalm/Internal/Fork/ForkProcessDoneMessage.php index c845be80315..8129dd0ac69 100644 --- a/src/Psalm/Internal/Fork/ForkProcessDoneMessage.php +++ b/src/Psalm/Internal/Fork/ForkProcessDoneMessage.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class ForkProcessDoneMessage implements ForkMessage +final class ForkProcessDoneMessage implements ForkMessage { use ImmutableNonCloneableTrait; /** @var mixed */ diff --git a/src/Psalm/Internal/Fork/ForkProcessErrorMessage.php b/src/Psalm/Internal/Fork/ForkProcessErrorMessage.php index 6bf9acb2c12..43f4b4ceaa6 100644 --- a/src/Psalm/Internal/Fork/ForkProcessErrorMessage.php +++ b/src/Psalm/Internal/Fork/ForkProcessErrorMessage.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class ForkProcessErrorMessage implements ForkMessage +final class ForkProcessErrorMessage implements ForkMessage { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/Fork/ForkTaskDoneMessage.php b/src/Psalm/Internal/Fork/ForkTaskDoneMessage.php index 11fff6edbd3..591b472db4b 100644 --- a/src/Psalm/Internal/Fork/ForkTaskDoneMessage.php +++ b/src/Psalm/Internal/Fork/ForkTaskDoneMessage.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class ForkTaskDoneMessage implements ForkMessage +final class ForkTaskDoneMessage implements ForkMessage { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/Fork/Pool.php b/src/Psalm/Internal/Fork/Pool.php index 09e525dde6d..9311fc4d6fc 100644 --- a/src/Psalm/Internal/Fork/Pool.php +++ b/src/Psalm/Internal/Fork/Pool.php @@ -70,7 +70,7 @@ * * @internal */ -class Pool +final class Pool { private const EXIT_SUCCESS = 0; private const EXIT_FAILURE = 1; diff --git a/src/Psalm/Internal/Fork/PsalmRestarter.php b/src/Psalm/Internal/Fork/PsalmRestarter.php index 27840944143..53de9ec014c 100644 --- a/src/Psalm/Internal/Fork/PsalmRestarter.php +++ b/src/Psalm/Internal/Fork/PsalmRestarter.php @@ -22,7 +22,7 @@ /** * @internal */ -class PsalmRestarter extends XdebugHandler +final class PsalmRestarter extends XdebugHandler { private const REQUIRED_OPCACHE_SETTINGS = [ 'enable_cli' => true, diff --git a/src/Psalm/Internal/Json/Json.php b/src/Psalm/Internal/Json/Json.php index 10c823d2773..9cd7ebb743a 100644 --- a/src/Psalm/Internal/Json/Json.php +++ b/src/Psalm/Internal/Json/Json.php @@ -16,7 +16,7 @@ * * @internal */ -class Json +final class Json { public const PRETTY = JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE; diff --git a/src/Psalm/Internal/LanguageServer/Client/TextDocument.php b/src/Psalm/Internal/LanguageServer/Client/TextDocument.php index c7f4e378656..1e65565df3c 100644 --- a/src/Psalm/Internal/LanguageServer/Client/TextDocument.php +++ b/src/Psalm/Internal/LanguageServer/Client/TextDocument.php @@ -13,7 +13,7 @@ * * @internal */ -class TextDocument +final class TextDocument { private ClientHandler $handler; diff --git a/src/Psalm/Internal/LanguageServer/Client/Workspace.php b/src/Psalm/Internal/LanguageServer/Client/Workspace.php index f9d9cf39e90..0df62350373 100644 --- a/src/Psalm/Internal/LanguageServer/Client/Workspace.php +++ b/src/Psalm/Internal/LanguageServer/Client/Workspace.php @@ -14,7 +14,7 @@ * * @internal */ -class Workspace +final class Workspace { private ClientHandler $handler; diff --git a/src/Psalm/Internal/LanguageServer/ClientConfiguration.php b/src/Psalm/Internal/LanguageServer/ClientConfiguration.php index 115a38f6567..788d699fc16 100644 --- a/src/Psalm/Internal/LanguageServer/ClientConfiguration.php +++ b/src/Psalm/Internal/LanguageServer/ClientConfiguration.php @@ -9,7 +9,7 @@ /** * @internal */ -class ClientConfiguration +final class ClientConfiguration { /** diff --git a/src/Psalm/Internal/LanguageServer/ClientHandler.php b/src/Psalm/Internal/LanguageServer/ClientHandler.php index 06e48e3d143..5c2588516cf 100644 --- a/src/Psalm/Internal/LanguageServer/ClientHandler.php +++ b/src/Psalm/Internal/LanguageServer/ClientHandler.php @@ -17,7 +17,7 @@ /** * @internal */ -class ClientHandler +final class ClientHandler { public ProtocolReader $protocolReader; diff --git a/src/Psalm/Internal/LanguageServer/IdGenerator.php b/src/Psalm/Internal/LanguageServer/IdGenerator.php index 330015db5e7..29540b62625 100644 --- a/src/Psalm/Internal/LanguageServer/IdGenerator.php +++ b/src/Psalm/Internal/LanguageServer/IdGenerator.php @@ -9,7 +9,7 @@ * * @internal */ -class IdGenerator +final class IdGenerator { public int $counter = 1; diff --git a/src/Psalm/Internal/LanguageServer/LanguageClient.php b/src/Psalm/Internal/LanguageServer/LanguageClient.php index 9b092510e8d..4575aa3d575 100644 --- a/src/Psalm/Internal/LanguageServer/LanguageClient.php +++ b/src/Psalm/Internal/LanguageServer/LanguageClient.php @@ -20,7 +20,7 @@ /** * @internal */ -class LanguageClient +final class LanguageClient { /** * Handles textDocument/* methods diff --git a/src/Psalm/Internal/LanguageServer/LanguageServer.php b/src/Psalm/Internal/LanguageServer/LanguageServer.php index fde6b541395..4b10f55ef27 100644 --- a/src/Psalm/Internal/LanguageServer/LanguageServer.php +++ b/src/Psalm/Internal/LanguageServer/LanguageServer.php @@ -99,7 +99,7 @@ * @psalm-api * @internal */ -class LanguageServer extends Dispatcher +final class LanguageServer extends Dispatcher { /** * Handles textDocument/* method calls diff --git a/src/Psalm/Internal/LanguageServer/Message.php b/src/Psalm/Internal/LanguageServer/Message.php index 56b46c23350..400cf9d0dbb 100644 --- a/src/Psalm/Internal/LanguageServer/Message.php +++ b/src/Psalm/Internal/LanguageServer/Message.php @@ -13,7 +13,7 @@ /** * @internal */ -class Message +final class Message { public ?MessageBody $body = null; diff --git a/src/Psalm/Internal/LanguageServer/PHPMarkdownContent.php b/src/Psalm/Internal/LanguageServer/PHPMarkdownContent.php index 3290ea5cd4c..0f954b257a3 100644 --- a/src/Psalm/Internal/LanguageServer/PHPMarkdownContent.php +++ b/src/Psalm/Internal/LanguageServer/PHPMarkdownContent.php @@ -15,7 +15,7 @@ * @psalm-api * @internal */ -class PHPMarkdownContent extends MarkupContent implements JsonSerializable +final class PHPMarkdownContent extends MarkupContent implements JsonSerializable { public string $code; diff --git a/src/Psalm/Internal/LanguageServer/Progress.php b/src/Psalm/Internal/LanguageServer/Progress.php index 8512b8055f8..50f74472c00 100644 --- a/src/Psalm/Internal/LanguageServer/Progress.php +++ b/src/Psalm/Internal/LanguageServer/Progress.php @@ -9,7 +9,7 @@ /** * @internal */ -class Progress extends Base +final class Progress extends Base { private ?LanguageServer $server = null; diff --git a/src/Psalm/Internal/LanguageServer/ProtocolStreamReader.php b/src/Psalm/Internal/LanguageServer/ProtocolStreamReader.php index 35031d8541d..026a6a7d56e 100644 --- a/src/Psalm/Internal/LanguageServer/ProtocolStreamReader.php +++ b/src/Psalm/Internal/LanguageServer/ProtocolStreamReader.php @@ -21,7 +21,7 @@ * * @internal */ -class ProtocolStreamReader implements ProtocolReader +final class ProtocolStreamReader implements ProtocolReader { use EmitterTrait; diff --git a/src/Psalm/Internal/LanguageServer/ProtocolStreamWriter.php b/src/Psalm/Internal/LanguageServer/ProtocolStreamWriter.php index 10d86e14cd9..fe9cdd86a29 100644 --- a/src/Psalm/Internal/LanguageServer/ProtocolStreamWriter.php +++ b/src/Psalm/Internal/LanguageServer/ProtocolStreamWriter.php @@ -10,7 +10,7 @@ /** * @internal */ -class ProtocolStreamWriter implements ProtocolWriter +final class ProtocolStreamWriter implements ProtocolWriter { private ResourceOutputStream $output; diff --git a/src/Psalm/Internal/LanguageServer/Provider/ClassLikeStorageCacheProvider.php b/src/Psalm/Internal/LanguageServer/Provider/ClassLikeStorageCacheProvider.php index f1925fe7904..1dbc6387d45 100644 --- a/src/Psalm/Internal/LanguageServer/Provider/ClassLikeStorageCacheProvider.php +++ b/src/Psalm/Internal/LanguageServer/Provider/ClassLikeStorageCacheProvider.php @@ -11,7 +11,7 @@ /** * @internal */ -class ClassLikeStorageCacheProvider extends InternalClassLikeStorageCacheProvider +final class ClassLikeStorageCacheProvider extends InternalClassLikeStorageCacheProvider { /** @var array */ private array $cache = []; diff --git a/src/Psalm/Internal/LanguageServer/Provider/FileReferenceCacheProvider.php b/src/Psalm/Internal/LanguageServer/Provider/FileReferenceCacheProvider.php index ca12912ec0a..b4476c2e118 100644 --- a/src/Psalm/Internal/LanguageServer/Provider/FileReferenceCacheProvider.php +++ b/src/Psalm/Internal/LanguageServer/Provider/FileReferenceCacheProvider.php @@ -11,7 +11,7 @@ * * @internal */ -class FileReferenceCacheProvider extends InternalFileReferenceCacheProvider +final class FileReferenceCacheProvider extends InternalFileReferenceCacheProvider { private ?array $cached_file_references = null; diff --git a/src/Psalm/Internal/LanguageServer/Provider/FileStorageCacheProvider.php b/src/Psalm/Internal/LanguageServer/Provider/FileStorageCacheProvider.php index 8841cf407a8..54186f6466f 100644 --- a/src/Psalm/Internal/LanguageServer/Provider/FileStorageCacheProvider.php +++ b/src/Psalm/Internal/LanguageServer/Provider/FileStorageCacheProvider.php @@ -10,7 +10,7 @@ /** * @internal */ -class FileStorageCacheProvider extends InternalFileStorageCacheProvider +final class FileStorageCacheProvider extends InternalFileStorageCacheProvider { /** @var array */ private array $cache = []; diff --git a/src/Psalm/Internal/LanguageServer/Provider/ParserCacheProvider.php b/src/Psalm/Internal/LanguageServer/Provider/ParserCacheProvider.php index 0b30a2dda57..498126d69c1 100644 --- a/src/Psalm/Internal/LanguageServer/Provider/ParserCacheProvider.php +++ b/src/Psalm/Internal/LanguageServer/Provider/ParserCacheProvider.php @@ -10,7 +10,7 @@ /** * @internal */ -class ParserCacheProvider extends InternalParserCacheProvider +final class ParserCacheProvider extends InternalParserCacheProvider { /** * @var array diff --git a/src/Psalm/Internal/LanguageServer/Provider/ProjectCacheProvider.php b/src/Psalm/Internal/LanguageServer/Provider/ProjectCacheProvider.php index ed210fa0ae2..80f758c83ca 100644 --- a/src/Psalm/Internal/LanguageServer/Provider/ProjectCacheProvider.php +++ b/src/Psalm/Internal/LanguageServer/Provider/ProjectCacheProvider.php @@ -7,7 +7,7 @@ /** * @internal */ -class ProjectCacheProvider extends PsalmProjectCacheProvider +final class ProjectCacheProvider extends PsalmProjectCacheProvider { private int $last_run = 0; diff --git a/src/Psalm/Internal/LanguageServer/Reference.php b/src/Psalm/Internal/LanguageServer/Reference.php index 32694c7c8df..345b08705e3 100644 --- a/src/Psalm/Internal/LanguageServer/Reference.php +++ b/src/Psalm/Internal/LanguageServer/Reference.php @@ -7,7 +7,7 @@ /** * @internal */ -class Reference +final class Reference { public string $file_path; public string $symbol; diff --git a/src/Psalm/Internal/LanguageServer/Server/TextDocument.php b/src/Psalm/Internal/LanguageServer/Server/TextDocument.php index cb359d5b9fe..a4af46cacec 100644 --- a/src/Psalm/Internal/LanguageServer/Server/TextDocument.php +++ b/src/Psalm/Internal/LanguageServer/Server/TextDocument.php @@ -38,7 +38,7 @@ * * @internal */ -class TextDocument +final class TextDocument { protected LanguageServer $server; diff --git a/src/Psalm/Internal/LanguageServer/Server/Workspace.php b/src/Psalm/Internal/LanguageServer/Server/Workspace.php index 6d2e1622575..75c810cf800 100644 --- a/src/Psalm/Internal/LanguageServer/Server/Workspace.php +++ b/src/Psalm/Internal/LanguageServer/Server/Workspace.php @@ -25,7 +25,7 @@ * * @internal */ -class Workspace +final class Workspace { protected LanguageServer $server; diff --git a/src/Psalm/Internal/MethodIdentifier.php b/src/Psalm/Internal/MethodIdentifier.php index ad519202430..8d2d18d6d23 100644 --- a/src/Psalm/Internal/MethodIdentifier.php +++ b/src/Psalm/Internal/MethodIdentifier.php @@ -15,7 +15,7 @@ * @psalm-immutable * @internal */ -class MethodIdentifier +final class MethodIdentifier { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/PhpTraverser/CustomTraverser.php b/src/Psalm/Internal/PhpTraverser/CustomTraverser.php index 0f6279770d6..f1e2673572d 100644 --- a/src/Psalm/Internal/PhpTraverser/CustomTraverser.php +++ b/src/Psalm/Internal/PhpTraverser/CustomTraverser.php @@ -16,7 +16,7 @@ /** * @internal */ -class CustomTraverser extends NodeTraverser +final class CustomTraverser extends NodeTraverser { public function __construct() { diff --git a/src/Psalm/Internal/PhpVisitor/AssignmentMapVisitor.php b/src/Psalm/Internal/PhpVisitor/AssignmentMapVisitor.php index 703db43da3c..28b3770c167 100644 --- a/src/Psalm/Internal/PhpVisitor/AssignmentMapVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/AssignmentMapVisitor.php @@ -13,7 +13,7 @@ * With this map we can calculate how many times the loop analysis must * be run before all variables have the correct types */ -class AssignmentMapVisitor extends PhpParser\NodeVisitorAbstract +final class AssignmentMapVisitor extends PhpParser\NodeVisitorAbstract { /** * @var array> diff --git a/src/Psalm/Internal/PhpVisitor/CheckTrivialExprVisitor.php b/src/Psalm/Internal/PhpVisitor/CheckTrivialExprVisitor.php index c3289c5e3c4..4fe4afe5269 100644 --- a/src/Psalm/Internal/PhpVisitor/CheckTrivialExprVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/CheckTrivialExprVisitor.php @@ -7,7 +7,7 @@ /** * @internal */ -class CheckTrivialExprVisitor extends PhpParser\NodeVisitorAbstract +final class CheckTrivialExprVisitor extends PhpParser\NodeVisitorAbstract { /** * @var array diff --git a/src/Psalm/Internal/PhpVisitor/CloningVisitor.php b/src/Psalm/Internal/PhpVisitor/CloningVisitor.php index f6a089b1f87..1005caee248 100644 --- a/src/Psalm/Internal/PhpVisitor/CloningVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/CloningVisitor.php @@ -14,7 +14,7 @@ * * @internal */ -class CloningVisitor extends NodeVisitorAbstract +final class CloningVisitor extends NodeVisitorAbstract { public function enterNode(Node $node): Node { diff --git a/src/Psalm/Internal/PhpVisitor/ConditionCloningVisitor.php b/src/Psalm/Internal/PhpVisitor/ConditionCloningVisitor.php index b1e4018a1b0..c0c4d3e3f5a 100644 --- a/src/Psalm/Internal/PhpVisitor/ConditionCloningVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/ConditionCloningVisitor.php @@ -12,7 +12,7 @@ /** * @internal */ -class ConditionCloningVisitor extends NodeVisitorAbstract +final class ConditionCloningVisitor extends NodeVisitorAbstract { private NodeDataProvider $type_provider; diff --git a/src/Psalm/Internal/PhpVisitor/NodeCleanerVisitor.php b/src/Psalm/Internal/PhpVisitor/NodeCleanerVisitor.php index 2342123c24c..d7a9ab78dbc 100644 --- a/src/Psalm/Internal/PhpVisitor/NodeCleanerVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/NodeCleanerVisitor.php @@ -8,7 +8,7 @@ /** * @internal */ -class NodeCleanerVisitor extends PhpParser\NodeVisitorAbstract +final class NodeCleanerVisitor extends PhpParser\NodeVisitorAbstract { private NodeDataProvider $type_provider; diff --git a/src/Psalm/Internal/PhpVisitor/NodeCounterVisitor.php b/src/Psalm/Internal/PhpVisitor/NodeCounterVisitor.php index fadcf34e4a0..c889bd2fe42 100644 --- a/src/Psalm/Internal/PhpVisitor/NodeCounterVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/NodeCounterVisitor.php @@ -7,7 +7,7 @@ /** * @internal */ -class NodeCounterVisitor extends PhpParser\NodeVisitorAbstract +final class NodeCounterVisitor extends PhpParser\NodeVisitorAbstract { public int $count = 0; diff --git a/src/Psalm/Internal/PhpVisitor/OffsetShifterVisitor.php b/src/Psalm/Internal/PhpVisitor/OffsetShifterVisitor.php index 2f6e1567d1d..9937ec8bb7e 100644 --- a/src/Psalm/Internal/PhpVisitor/OffsetShifterVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/OffsetShifterVisitor.php @@ -9,7 +9,7 @@ * * @internal */ -class OffsetShifterVisitor extends PhpParser\NodeVisitorAbstract +final class OffsetShifterVisitor extends PhpParser\NodeVisitorAbstract { private int $file_offset; diff --git a/src/Psalm/Internal/PhpVisitor/ParamReplacementVisitor.php b/src/Psalm/Internal/PhpVisitor/ParamReplacementVisitor.php index 11f1604b1a4..ce3574db13c 100644 --- a/src/Psalm/Internal/PhpVisitor/ParamReplacementVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/ParamReplacementVisitor.php @@ -14,7 +14,7 @@ /** * @internal */ -class ParamReplacementVisitor extends PhpParser\NodeVisitorAbstract +final class ParamReplacementVisitor extends PhpParser\NodeVisitorAbstract { private string $old_name; diff --git a/src/Psalm/Internal/PhpVisitor/PartialParserVisitor.php b/src/Psalm/Internal/PhpVisitor/PartialParserVisitor.php index d1c09f32478..59343c14c1b 100644 --- a/src/Psalm/Internal/PhpVisitor/PartialParserVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/PartialParserVisitor.php @@ -28,7 +28,7 @@ * * @internal */ -class PartialParserVisitor extends PhpParser\NodeVisitorAbstract +final class PartialParserVisitor extends PhpParser\NodeVisitorAbstract { /** @var array */ private array $offset_map; diff --git a/src/Psalm/Internal/PhpVisitor/Reflector/AttributeResolver.php b/src/Psalm/Internal/PhpVisitor/Reflector/AttributeResolver.php index 339d86229d0..63ec7c07293 100644 --- a/src/Psalm/Internal/PhpVisitor/Reflector/AttributeResolver.php +++ b/src/Psalm/Internal/PhpVisitor/Reflector/AttributeResolver.php @@ -20,7 +20,7 @@ /** * @internal */ -class AttributeResolver +final class AttributeResolver { public static function resolve( Codebase $codebase, diff --git a/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeDocblockParser.php b/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeDocblockParser.php index 2f1c5467b93..1d48be61220 100644 --- a/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeDocblockParser.php +++ b/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeDocblockParser.php @@ -48,7 +48,7 @@ /** * @internal */ -class ClassLikeDocblockParser +final class ClassLikeDocblockParser { /** * @throws DocblockParseException if there was a problem parsing the docblock diff --git a/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeNodeScanner.php b/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeNodeScanner.php index fae0c8daf26..c4a6e3b491a 100644 --- a/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeNodeScanner.php +++ b/src/Psalm/Internal/PhpVisitor/Reflector/ClassLikeNodeScanner.php @@ -92,7 +92,7 @@ /** * @internal */ -class ClassLikeNodeScanner +final class ClassLikeNodeScanner { private FileScanner $file_scanner; diff --git a/src/Psalm/Internal/PhpVisitor/Reflector/ExpressionResolver.php b/src/Psalm/Internal/PhpVisitor/Reflector/ExpressionResolver.php index ac05615b4fe..cf5dd8a0519 100644 --- a/src/Psalm/Internal/PhpVisitor/Reflector/ExpressionResolver.php +++ b/src/Psalm/Internal/PhpVisitor/Reflector/ExpressionResolver.php @@ -45,7 +45,7 @@ /** * @internal */ -class ExpressionResolver +final class ExpressionResolver { public static function getUnresolvedClassConstExpr( PhpParser\Node\Expr $stmt, diff --git a/src/Psalm/Internal/PhpVisitor/Reflector/ExpressionScanner.php b/src/Psalm/Internal/PhpVisitor/Reflector/ExpressionScanner.php index 696b7497d70..6afd142bfa5 100644 --- a/src/Psalm/Internal/PhpVisitor/Reflector/ExpressionScanner.php +++ b/src/Psalm/Internal/PhpVisitor/Reflector/ExpressionScanner.php @@ -36,7 +36,7 @@ /** * @internal */ -class ExpressionScanner +final class ExpressionScanner { public static function scan( Codebase $codebase, diff --git a/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockParser.php b/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockParser.php index 7ade521fd10..e2a2cc5a14b 100644 --- a/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockParser.php +++ b/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockParser.php @@ -39,7 +39,7 @@ /** * @internal */ -class FunctionLikeDocblockParser +final class FunctionLikeDocblockParser { /** * @throws DocblockParseException if there was a problem parsing the docblock diff --git a/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockScanner.php b/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockScanner.php index 9f9a477cb4d..828d894763e 100644 --- a/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockScanner.php +++ b/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeDocblockScanner.php @@ -69,7 +69,7 @@ /** * @internal */ -class FunctionLikeDocblockScanner +final class FunctionLikeDocblockScanner { /** * @param array> $existing_function_template_types diff --git a/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeNodeScanner.php b/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeNodeScanner.php index e0ba4e3478b..f04a90072d0 100644 --- a/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeNodeScanner.php +++ b/src/Psalm/Internal/PhpVisitor/Reflector/FunctionLikeNodeScanner.php @@ -66,7 +66,7 @@ /** * @internal */ -class FunctionLikeNodeScanner +final class FunctionLikeNodeScanner { private FileScanner $file_scanner; diff --git a/src/Psalm/Internal/PhpVisitor/Reflector/TypeHintResolver.php b/src/Psalm/Internal/PhpVisitor/Reflector/TypeHintResolver.php index 3e5fcef5d45..41c91d9ad39 100644 --- a/src/Psalm/Internal/PhpVisitor/Reflector/TypeHintResolver.php +++ b/src/Psalm/Internal/PhpVisitor/Reflector/TypeHintResolver.php @@ -26,7 +26,7 @@ /** * @internal */ -class TypeHintResolver +final class TypeHintResolver { /** * @param Identifier|IntersectionType|Name|NullableType|UnionType $hint diff --git a/src/Psalm/Internal/PhpVisitor/ReflectorVisitor.php b/src/Psalm/Internal/PhpVisitor/ReflectorVisitor.php index 734c14d8b11..85d538c3ea8 100644 --- a/src/Psalm/Internal/PhpVisitor/ReflectorVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/ReflectorVisitor.php @@ -51,7 +51,7 @@ /** * @internal */ -class ReflectorVisitor extends PhpParser\NodeVisitorAbstract implements FileSource +final class ReflectorVisitor extends PhpParser\NodeVisitorAbstract implements FileSource { private Aliases $aliases; diff --git a/src/Psalm/Internal/PhpVisitor/ShortClosureVisitor.php b/src/Psalm/Internal/PhpVisitor/ShortClosureVisitor.php index fe0bd1f4a92..aa14b34613a 100644 --- a/src/Psalm/Internal/PhpVisitor/ShortClosureVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/ShortClosureVisitor.php @@ -9,7 +9,7 @@ /** * @internal */ -class ShortClosureVisitor extends PhpParser\NodeVisitorAbstract +final class ShortClosureVisitor extends PhpParser\NodeVisitorAbstract { /** * @var array diff --git a/src/Psalm/Internal/PhpVisitor/SimpleNameResolver.php b/src/Psalm/Internal/PhpVisitor/SimpleNameResolver.php index d33c19d64e8..1eca6d3fd10 100644 --- a/src/Psalm/Internal/PhpVisitor/SimpleNameResolver.php +++ b/src/Psalm/Internal/PhpVisitor/SimpleNameResolver.php @@ -17,7 +17,7 @@ /** * @internal */ -class SimpleNameResolver extends NodeVisitorAbstract +final class SimpleNameResolver extends NodeVisitorAbstract { private NameContext $nameContext; diff --git a/src/Psalm/Internal/PhpVisitor/TraitFinder.php b/src/Psalm/Internal/PhpVisitor/TraitFinder.php index 9d5717dad10..eefc452b274 100644 --- a/src/Psalm/Internal/PhpVisitor/TraitFinder.php +++ b/src/Psalm/Internal/PhpVisitor/TraitFinder.php @@ -17,7 +17,7 @@ * * @internal */ -class TraitFinder extends PhpParser\NodeVisitorAbstract +final class TraitFinder extends PhpParser\NodeVisitorAbstract { /** @var list */ private array $matching_trait_nodes = []; diff --git a/src/Psalm/Internal/PhpVisitor/TypeMappingVisitor.php b/src/Psalm/Internal/PhpVisitor/TypeMappingVisitor.php index 354a639e4cc..a42a9881dbf 100644 --- a/src/Psalm/Internal/PhpVisitor/TypeMappingVisitor.php +++ b/src/Psalm/Internal/PhpVisitor/TypeMappingVisitor.php @@ -11,7 +11,7 @@ /** * @internal */ -class TypeMappingVisitor extends NodeVisitorAbstract +final class TypeMappingVisitor extends NodeVisitorAbstract { private NodeDataProvider $fake_type_provider; private NodeDataProvider $real_type_provider; diff --git a/src/Psalm/Internal/PhpVisitor/YieldTypeCollector.php b/src/Psalm/Internal/PhpVisitor/YieldTypeCollector.php index 4d9f075a5e7..881b28b3644 100644 --- a/src/Psalm/Internal/PhpVisitor/YieldTypeCollector.php +++ b/src/Psalm/Internal/PhpVisitor/YieldTypeCollector.php @@ -16,7 +16,7 @@ /** * @internal */ -class YieldTypeCollector extends NodeVisitorAbstract +final class YieldTypeCollector extends NodeVisitorAbstract { /** @var list */ private array $yield_types = []; diff --git a/src/Psalm/Internal/PluginManager/Command/DisableCommand.php b/src/Psalm/Internal/PluginManager/Command/DisableCommand.php index c6b5dd1d89e..af7b4bb90d9 100644 --- a/src/Psalm/Internal/PluginManager/Command/DisableCommand.php +++ b/src/Psalm/Internal/PluginManager/Command/DisableCommand.php @@ -21,7 +21,7 @@ /** * @internal */ -class DisableCommand extends Command +final class DisableCommand extends Command { private PluginListFactory $plugin_list_factory; diff --git a/src/Psalm/Internal/PluginManager/Command/EnableCommand.php b/src/Psalm/Internal/PluginManager/Command/EnableCommand.php index c520dac31b5..6278b7018f2 100644 --- a/src/Psalm/Internal/PluginManager/Command/EnableCommand.php +++ b/src/Psalm/Internal/PluginManager/Command/EnableCommand.php @@ -21,7 +21,7 @@ /** * @internal */ -class EnableCommand extends Command +final class EnableCommand extends Command { private PluginListFactory $plugin_list_factory; diff --git a/src/Psalm/Internal/PluginManager/Command/ShowCommand.php b/src/Psalm/Internal/PluginManager/Command/ShowCommand.php index 40ac6d0638b..a8e78a732c4 100644 --- a/src/Psalm/Internal/PluginManager/Command/ShowCommand.php +++ b/src/Psalm/Internal/PluginManager/Command/ShowCommand.php @@ -22,7 +22,7 @@ /** * @internal */ -class ShowCommand extends Command +final class ShowCommand extends Command { private PluginListFactory $plugin_list_factory; diff --git a/src/Psalm/Internal/PluginManager/ComposerLock.php b/src/Psalm/Internal/PluginManager/ComposerLock.php index e9c36807c87..43bfdcfceaa 100644 --- a/src/Psalm/Internal/PluginManager/ComposerLock.php +++ b/src/Psalm/Internal/PluginManager/ComposerLock.php @@ -15,7 +15,7 @@ /** * @internal */ -class ComposerLock +final class ComposerLock { /** @var string[] */ private array $file_names; diff --git a/src/Psalm/Internal/PluginManager/ConfigFile.php b/src/Psalm/Internal/PluginManager/ConfigFile.php index 84ffed92ff6..4fdc21a8823 100644 --- a/src/Psalm/Internal/PluginManager/ConfigFile.php +++ b/src/Psalm/Internal/PluginManager/ConfigFile.php @@ -17,7 +17,7 @@ /** * @internal */ -class ConfigFile +final class ConfigFile { private string $path; diff --git a/src/Psalm/Internal/PluginManager/PluginList.php b/src/Psalm/Internal/PluginManager/PluginList.php index 789dcc0ad0a..0eb325bd28c 100644 --- a/src/Psalm/Internal/PluginManager/PluginList.php +++ b/src/Psalm/Internal/PluginManager/PluginList.php @@ -14,7 +14,7 @@ /** * @internal */ -class PluginList +final class PluginList { private ?ConfigFile $config_file = null; diff --git a/src/Psalm/Internal/PluginManager/PluginListFactory.php b/src/Psalm/Internal/PluginManager/PluginListFactory.php index e6104032776..950b6dd24a6 100644 --- a/src/Psalm/Internal/PluginManager/PluginListFactory.php +++ b/src/Psalm/Internal/PluginManager/PluginListFactory.php @@ -16,7 +16,7 @@ /** * @internal */ -class PluginListFactory +final class PluginListFactory { private string $project_root; diff --git a/src/Psalm/Internal/Provider/AddRemoveTaints/HtmlFunctionTainter.php b/src/Psalm/Internal/Provider/AddRemoveTaints/HtmlFunctionTainter.php index 1f862278d48..d49ebcee48b 100644 --- a/src/Psalm/Internal/Provider/AddRemoveTaints/HtmlFunctionTainter.php +++ b/src/Psalm/Internal/Provider/AddRemoveTaints/HtmlFunctionTainter.php @@ -16,7 +16,7 @@ /** * @internal */ -class HtmlFunctionTainter implements AddTaintsInterface, RemoveTaintsInterface +final class HtmlFunctionTainter implements AddTaintsInterface, RemoveTaintsInterface { /** * Called to see what taints should be added diff --git a/src/Psalm/Internal/Provider/ClassLikeStorageProvider.php b/src/Psalm/Internal/Provider/ClassLikeStorageProvider.php index 9b8c82617ea..353bdb3f408 100644 --- a/src/Psalm/Internal/Provider/ClassLikeStorageProvider.php +++ b/src/Psalm/Internal/Provider/ClassLikeStorageProvider.php @@ -12,7 +12,7 @@ /** * @internal */ -class ClassLikeStorageProvider +final class ClassLikeStorageProvider { /** * Storing this statically is much faster (at least in PHP 7.2.1) diff --git a/src/Psalm/Internal/Provider/FakeFileProvider.php b/src/Psalm/Internal/Provider/FakeFileProvider.php index 756e0d72806..734cd64dab8 100644 --- a/src/Psalm/Internal/Provider/FakeFileProvider.php +++ b/src/Psalm/Internal/Provider/FakeFileProvider.php @@ -8,7 +8,7 @@ /** * @internal */ -class FakeFileProvider extends FileProvider +final class FakeFileProvider extends FileProvider { /** * @var array diff --git a/src/Psalm/Internal/Provider/FileReferenceProvider.php b/src/Psalm/Internal/Provider/FileReferenceProvider.php index 15950320835..b89a2604128 100644 --- a/src/Psalm/Internal/Provider/FileReferenceProvider.php +++ b/src/Psalm/Internal/Provider/FileReferenceProvider.php @@ -22,7 +22,7 @@ * @psalm-import-type FileMapType from Analyzer * @internal */ -class FileReferenceProvider +final class FileReferenceProvider { private bool $loaded_from_cache = false; diff --git a/src/Psalm/Internal/Provider/FileStorageProvider.php b/src/Psalm/Internal/Provider/FileStorageProvider.php index 946d3c46062..91bbbbe8c52 100644 --- a/src/Psalm/Internal/Provider/FileStorageProvider.php +++ b/src/Psalm/Internal/Provider/FileStorageProvider.php @@ -11,7 +11,7 @@ /** * @internal */ -class FileStorageProvider +final class FileStorageProvider { /** * A list of data useful to analyse files diff --git a/src/Psalm/Internal/Provider/FunctionExistenceProvider.php b/src/Psalm/Internal/Provider/FunctionExistenceProvider.php index a3c2f7e17e5..3f5c96f5f5c 100644 --- a/src/Psalm/Internal/Provider/FunctionExistenceProvider.php +++ b/src/Psalm/Internal/Provider/FunctionExistenceProvider.php @@ -13,7 +13,7 @@ /** * @internal */ -class FunctionExistenceProvider +final class FunctionExistenceProvider { /** * @var array< diff --git a/src/Psalm/Internal/Provider/FunctionParamsProvider.php b/src/Psalm/Internal/Provider/FunctionParamsProvider.php index cd83b294ac6..b34d2b0a10d 100644 --- a/src/Psalm/Internal/Provider/FunctionParamsProvider.php +++ b/src/Psalm/Internal/Provider/FunctionParamsProvider.php @@ -16,7 +16,7 @@ /** * @internal */ -class FunctionParamsProvider +final class FunctionParamsProvider { /** * @var array< diff --git a/src/Psalm/Internal/Provider/FunctionReturnTypeProvider.php b/src/Psalm/Internal/Provider/FunctionReturnTypeProvider.php index ab43dcf5c17..04a5a74d572 100644 --- a/src/Psalm/Internal/Provider/FunctionReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/FunctionReturnTypeProvider.php @@ -55,7 +55,7 @@ /** * @internal */ -class FunctionReturnTypeProvider +final class FunctionReturnTypeProvider { /** * @var array< diff --git a/src/Psalm/Internal/Provider/MethodExistenceProvider.php b/src/Psalm/Internal/Provider/MethodExistenceProvider.php index 6d3b9612980..7f85cf9e6ed 100644 --- a/src/Psalm/Internal/Provider/MethodExistenceProvider.php +++ b/src/Psalm/Internal/Provider/MethodExistenceProvider.php @@ -13,7 +13,7 @@ /** * @internal */ -class MethodExistenceProvider +final class MethodExistenceProvider { /** * @var array< diff --git a/src/Psalm/Internal/Provider/MethodParamsProvider.php b/src/Psalm/Internal/Provider/MethodParamsProvider.php index a8faa312ccd..7074627cd05 100644 --- a/src/Psalm/Internal/Provider/MethodParamsProvider.php +++ b/src/Psalm/Internal/Provider/MethodParamsProvider.php @@ -19,7 +19,7 @@ /** * @internal */ -class MethodParamsProvider +final class MethodParamsProvider { /** * @var array< diff --git a/src/Psalm/Internal/Provider/MethodReturnTypeProvider.php b/src/Psalm/Internal/Provider/MethodReturnTypeProvider.php index bba8d867243..a892575be77 100644 --- a/src/Psalm/Internal/Provider/MethodReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/MethodReturnTypeProvider.php @@ -22,7 +22,7 @@ /** * @internal */ -class MethodReturnTypeProvider +final class MethodReturnTypeProvider { /** * @var array< diff --git a/src/Psalm/Internal/Provider/MethodVisibilityProvider.php b/src/Psalm/Internal/Provider/MethodVisibilityProvider.php index 276de010434..b4309d232df 100644 --- a/src/Psalm/Internal/Provider/MethodVisibilityProvider.php +++ b/src/Psalm/Internal/Provider/MethodVisibilityProvider.php @@ -15,7 +15,7 @@ /** * @internal */ -class MethodVisibilityProvider +final class MethodVisibilityProvider { /** * @var array< diff --git a/src/Psalm/Internal/Provider/NodeDataProvider.php b/src/Psalm/Internal/Provider/NodeDataProvider.php index 8b4a2274274..bf384767b32 100644 --- a/src/Psalm/Internal/Provider/NodeDataProvider.php +++ b/src/Psalm/Internal/Provider/NodeDataProvider.php @@ -20,7 +20,7 @@ /** * @internal */ -class NodeDataProvider implements NodeTypeProvider +final class NodeDataProvider implements NodeTypeProvider { /** @var SplObjectStorage */ private SplObjectStorage $node_types; diff --git a/src/Psalm/Internal/Provider/PropertyExistenceProvider.php b/src/Psalm/Internal/Provider/PropertyExistenceProvider.php index 9593ec3d183..101bf1c2fe7 100644 --- a/src/Psalm/Internal/Provider/PropertyExistenceProvider.php +++ b/src/Psalm/Internal/Provider/PropertyExistenceProvider.php @@ -15,7 +15,7 @@ /** * @internal */ -class PropertyExistenceProvider +final class PropertyExistenceProvider { /** * @var array< diff --git a/src/Psalm/Internal/Provider/PropertyTypeProvider.php b/src/Psalm/Internal/Provider/PropertyTypeProvider.php index 9fc62b024ac..0089621023e 100644 --- a/src/Psalm/Internal/Provider/PropertyTypeProvider.php +++ b/src/Psalm/Internal/Provider/PropertyTypeProvider.php @@ -16,7 +16,7 @@ /** * @internal */ -class PropertyTypeProvider +final class PropertyTypeProvider { /** * @var array< diff --git a/src/Psalm/Internal/Provider/PropertyTypeProvider/DomDocumentPropertyTypeProvider.php b/src/Psalm/Internal/Provider/PropertyTypeProvider/DomDocumentPropertyTypeProvider.php index d529abe1850..a76061780b8 100644 --- a/src/Psalm/Internal/Provider/PropertyTypeProvider/DomDocumentPropertyTypeProvider.php +++ b/src/Psalm/Internal/Provider/PropertyTypeProvider/DomDocumentPropertyTypeProvider.php @@ -15,7 +15,7 @@ /** * @internal */ -class DomDocumentPropertyTypeProvider implements PropertyTypeProviderInterface +final class DomDocumentPropertyTypeProvider implements PropertyTypeProviderInterface { private static ?Union $cache = null; public static function getPropertyType(PropertyTypeProviderEvent $event): ?Union diff --git a/src/Psalm/Internal/Provider/PropertyVisibilityProvider.php b/src/Psalm/Internal/Provider/PropertyVisibilityProvider.php index 099bf800733..ea0f450a6a7 100644 --- a/src/Psalm/Internal/Provider/PropertyVisibilityProvider.php +++ b/src/Psalm/Internal/Provider/PropertyVisibilityProvider.php @@ -14,7 +14,7 @@ /** * @internal */ -class PropertyVisibilityProvider +final class PropertyVisibilityProvider { /** * @var array< diff --git a/src/Psalm/Internal/Provider/Providers.php b/src/Psalm/Internal/Provider/Providers.php index b3a5a2a8abb..9e74bc67ef6 100644 --- a/src/Psalm/Internal/Provider/Providers.php +++ b/src/Psalm/Internal/Provider/Providers.php @@ -16,7 +16,7 @@ /** * @internal */ -class Providers +final class Providers { public FileProvider $file_provider; diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayChunkReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayChunkReturnTypeProvider.php index 5e949bec3e1..4e236619a13 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayChunkReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayChunkReturnTypeProvider.php @@ -16,7 +16,7 @@ /** * @internal */ -class ArrayChunkReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayChunkReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayColumnReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayColumnReturnTypeProvider.php index dbb3f3dfb36..22377c272e0 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayColumnReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayColumnReturnTypeProvider.php @@ -21,7 +21,7 @@ /** * @internal */ -class ArrayColumnReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayColumnReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayCombineReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayCombineReturnTypeProvider.php index 88125e398e3..57de9047e55 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayCombineReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayCombineReturnTypeProvider.php @@ -19,7 +19,7 @@ /** * @internal */ -class ArrayCombineReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayCombineReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFillKeysReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFillKeysReturnTypeProvider.php index c40175a13ea..8b891887b6d 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFillKeysReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFillKeysReturnTypeProvider.php @@ -15,7 +15,7 @@ /** * @internal */ -class ArrayFillKeysReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayFillKeysReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFillReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFillReturnTypeProvider.php index 3d0a08f2faf..7653fd64880 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFillReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFillReturnTypeProvider.php @@ -14,7 +14,7 @@ /** * @internal */ -class ArrayFillReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayFillReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFilterReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFilterReturnTypeProvider.php index 4f2a81e1f47..3e44102f912 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFilterReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayFilterReturnTypeProvider.php @@ -36,7 +36,7 @@ /** * @internal */ -class ArrayFilterReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayFilterReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayMapReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayMapReturnTypeProvider.php index 910c5d5c9e6..3d30faa936d 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayMapReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayMapReturnTypeProvider.php @@ -48,7 +48,7 @@ /** * @internal */ -class ArrayMapReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayMapReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayMergeReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayMergeReturnTypeProvider.php index 394988baee1..b93ff08826e 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayMergeReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayMergeReturnTypeProvider.php @@ -26,7 +26,7 @@ /** * @internal */ -class ArrayMergeReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayMergeReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPadReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPadReturnTypeProvider.php index f818945d779..ff616f908a9 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPadReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPadReturnTypeProvider.php @@ -17,7 +17,7 @@ /** * @internal */ -class ArrayPadReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayPadReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPointerAdjustmentReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPointerAdjustmentReturnTypeProvider.php index a9421acfa4c..df1c3a0518a 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPointerAdjustmentReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPointerAdjustmentReturnTypeProvider.php @@ -23,7 +23,7 @@ /** * @internal */ -class ArrayPointerAdjustmentReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayPointerAdjustmentReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * These functions are already handled by the CoreGenericFunctions stub diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPopReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPopReturnTypeProvider.php index 1d6806ffe7d..a167a8ea2b3 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPopReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayPopReturnTypeProvider.php @@ -15,7 +15,7 @@ /** * @internal */ -class ArrayPopReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayPopReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayRandReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayRandReturnTypeProvider.php index f4a6689051a..cb8e402dac5 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayRandReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayRandReturnTypeProvider.php @@ -13,7 +13,7 @@ /** * @internal */ -class ArrayRandReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayRandReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayReduceReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayReduceReturnTypeProvider.php index 9b4ee1dd53d..7153792184d 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayReduceReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayReduceReturnTypeProvider.php @@ -31,7 +31,7 @@ /** * @internal */ -class ArrayReduceReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayReduceReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayReverseReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayReverseReturnTypeProvider.php index 4a77a7322cb..8d20cd11b57 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayReverseReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArrayReverseReturnTypeProvider.php @@ -15,7 +15,7 @@ /** * @internal */ -class ArrayReverseReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArrayReverseReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArraySliceReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArraySliceReturnTypeProvider.php index 64d988b8498..122488bc257 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArraySliceReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArraySliceReturnTypeProvider.php @@ -19,7 +19,7 @@ /** * @internal */ -class ArraySliceReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArraySliceReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArraySpliceReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArraySpliceReturnTypeProvider.php index 90abc661e12..93bcd4c271e 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ArraySpliceReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ArraySpliceReturnTypeProvider.php @@ -13,7 +13,7 @@ /** * @internal */ -class ArraySpliceReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ArraySpliceReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/BasenameReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/BasenameReturnTypeProvider.php index 72d54927170..8e11092326e 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/BasenameReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/BasenameReturnTypeProvider.php @@ -16,7 +16,7 @@ /** * @internal */ -class BasenameReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class BasenameReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ClosureFromCallableReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ClosureFromCallableReturnTypeProvider.php index 9d33e12ef57..69c9f7ec020 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ClosureFromCallableReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ClosureFromCallableReturnTypeProvider.php @@ -14,7 +14,7 @@ /** * @internal */ -class ClosureFromCallableReturnTypeProvider implements MethodReturnTypeProviderInterface +final class ClosureFromCallableReturnTypeProvider implements MethodReturnTypeProviderInterface { public static function getClassLikeNames(): array { diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/DateReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/DateReturnTypeProvider.php index 13bc381defd..956bffb61e2 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/DateReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/DateReturnTypeProvider.php @@ -19,7 +19,7 @@ /** * @internal */ -class DateReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class DateReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/DateTimeModifyReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/DateTimeModifyReturnTypeProvider.php index b693d788ff1..2d2453fefdb 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/DateTimeModifyReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/DateTimeModifyReturnTypeProvider.php @@ -13,7 +13,7 @@ /** * @internal */ -class DateTimeModifyReturnTypeProvider implements MethodReturnTypeProviderInterface +final class DateTimeModifyReturnTypeProvider implements MethodReturnTypeProviderInterface { public static function getClassLikeNames(): array { diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/DirnameReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/DirnameReturnTypeProvider.php index 6d96bf81e35..f6c63c47ac4 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/DirnameReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/DirnameReturnTypeProvider.php @@ -19,7 +19,7 @@ /** * @internal */ -class DirnameReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class DirnameReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/DomNodeAppendChild.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/DomNodeAppendChild.php index e714f74c7c5..ee4de71ecf5 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/DomNodeAppendChild.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/DomNodeAppendChild.php @@ -11,7 +11,7 @@ /** * @internal */ -class DomNodeAppendChild implements MethodReturnTypeProviderInterface +final class DomNodeAppendChild implements MethodReturnTypeProviderInterface { public static function getClassLikeNames(): array { diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/FilterVarReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/FilterVarReturnTypeProvider.php index 19c839c44b3..bbf3642fa63 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/FilterVarReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/FilterVarReturnTypeProvider.php @@ -31,7 +31,7 @@ /** * @internal */ -class FilterVarReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class FilterVarReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/FirstArgStringReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/FirstArgStringReturnTypeProvider.php index 25332b58215..e9df5f741e5 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/FirstArgStringReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/FirstArgStringReturnTypeProvider.php @@ -13,7 +13,7 @@ /** * @internal */ -class FirstArgStringReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class FirstArgStringReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/GetClassMethodsReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/GetClassMethodsReturnTypeProvider.php index a5f07266a36..c2da32919ae 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/GetClassMethodsReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/GetClassMethodsReturnTypeProvider.php @@ -11,7 +11,7 @@ /** * @internal */ -class GetClassMethodsReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class GetClassMethodsReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/GetObjectVarsReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/GetObjectVarsReturnTypeProvider.php index 04b8b59cd51..55e4f38bd42 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/GetObjectVarsReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/GetObjectVarsReturnTypeProvider.php @@ -31,7 +31,7 @@ /** * @internal */ -class GetObjectVarsReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class GetObjectVarsReturnTypeProvider implements FunctionReturnTypeProviderInterface { public static function getFunctionIds(): array { diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/HexdecReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/HexdecReturnTypeProvider.php index 0cbd821ab00..f99d9bed7ef 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/HexdecReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/HexdecReturnTypeProvider.php @@ -11,7 +11,7 @@ /** * @internal */ -class HexdecReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class HexdecReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ImagickPixelColorReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ImagickPixelColorReturnTypeProvider.php index b756e98a5dc..1b121df74bc 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ImagickPixelColorReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ImagickPixelColorReturnTypeProvider.php @@ -16,7 +16,7 @@ /** * @internal */ -class ImagickPixelColorReturnTypeProvider implements MethodReturnTypeProviderInterface +final class ImagickPixelColorReturnTypeProvider implements MethodReturnTypeProviderInterface { public static function getClassLikeNames(): array { diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/InArrayReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/InArrayReturnTypeProvider.php index 4e675915e8e..c80b10f50dc 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/InArrayReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/InArrayReturnTypeProvider.php @@ -13,7 +13,7 @@ /** * @internal */ -class InArrayReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class InArrayReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/IteratorToArrayReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/IteratorToArrayReturnTypeProvider.php index 94167577fb5..db47500e12f 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/IteratorToArrayReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/IteratorToArrayReturnTypeProvider.php @@ -22,7 +22,7 @@ /** * @internal */ -class IteratorToArrayReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class IteratorToArrayReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/MbInternalEncodingReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/MbInternalEncodingReturnTypeProvider.php index 053efea8e1c..3c918678deb 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/MbInternalEncodingReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/MbInternalEncodingReturnTypeProvider.php @@ -21,7 +21,7 @@ /** * @internal */ -class MbInternalEncodingReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class MbInternalEncodingReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/MinMaxReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/MinMaxReturnTypeProvider.php index 2f4b7fffe87..db7000bc721 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/MinMaxReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/MinMaxReturnTypeProvider.php @@ -27,7 +27,7 @@ /** * @internal */ -class MinMaxReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class MinMaxReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/MktimeReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/MktimeReturnTypeProvider.php index 8eb1b7d2c02..a65b838b1a5 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/MktimeReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/MktimeReturnTypeProvider.php @@ -13,7 +13,7 @@ /** * @internal */ -class MktimeReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class MktimeReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/ParseUrlReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/ParseUrlReturnTypeProvider.php index bda2ab4f89e..5486741df63 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/ParseUrlReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/ParseUrlReturnTypeProvider.php @@ -29,7 +29,7 @@ /** * @internal */ -class ParseUrlReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class ParseUrlReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/PdoStatementReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/PdoStatementReturnTypeProvider.php index 0ed2c493f62..8c18ecfd9dc 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/PdoStatementReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/PdoStatementReturnTypeProvider.php @@ -17,7 +17,7 @@ /** * @internal */ -class PdoStatementReturnTypeProvider implements MethodReturnTypeProviderInterface +final class PdoStatementReturnTypeProvider implements MethodReturnTypeProviderInterface { public static function getClassLikeNames(): array { diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/PdoStatementSetFetchMode.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/PdoStatementSetFetchMode.php index cfb060f8e0c..91192788b3d 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/PdoStatementSetFetchMode.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/PdoStatementSetFetchMode.php @@ -12,7 +12,7 @@ /** * @internal */ -class PdoStatementSetFetchMode implements MethodParamsProviderInterface +final class PdoStatementSetFetchMode implements MethodParamsProviderInterface { public static function getClassLikeNames(): array { diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/PowReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/PowReturnTypeProvider.php index bffd07fcd3d..dcf7fb2db89 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/PowReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/PowReturnTypeProvider.php @@ -16,7 +16,7 @@ /** * @internal */ -class PowReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class PowReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/RandReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/RandReturnTypeProvider.php index ea6184e70fd..98ef8759223 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/RandReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/RandReturnTypeProvider.php @@ -16,7 +16,7 @@ /** * @internal */ -class RandReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class RandReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/RoundReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/RoundReturnTypeProvider.php index eb8ee561f54..32779b41f7e 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/RoundReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/RoundReturnTypeProvider.php @@ -18,7 +18,7 @@ /** * @internal */ -class RoundReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class RoundReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/SprintfReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/SprintfReturnTypeProvider.php index cca21b07ecf..3e7bbbc1283 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/SprintfReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/SprintfReturnTypeProvider.php @@ -31,7 +31,7 @@ /** * @internal */ -class SprintfReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class SprintfReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/StrReplaceReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/StrReplaceReturnTypeProvider.php index c7d64270691..78ebc6a32fb 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/StrReplaceReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/StrReplaceReturnTypeProvider.php @@ -14,7 +14,7 @@ /** * @internal */ -class StrReplaceReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class StrReplaceReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/StrTrReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/StrTrReturnTypeProvider.php index 721afd0713c..9994e696cba 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/StrTrReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/StrTrReturnTypeProvider.php @@ -15,7 +15,7 @@ /** * @internal */ -class StrTrReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class StrTrReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/TriggerErrorReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/TriggerErrorReturnTypeProvider.php index dfb8a173545..c0a812a40a7 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/TriggerErrorReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/TriggerErrorReturnTypeProvider.php @@ -25,7 +25,7 @@ /** * @internal */ -class TriggerErrorReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class TriggerErrorReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/ReturnTypeProvider/VersionCompareReturnTypeProvider.php b/src/Psalm/Internal/Provider/ReturnTypeProvider/VersionCompareReturnTypeProvider.php index 6340feddbaf..3b9d313db45 100644 --- a/src/Psalm/Internal/Provider/ReturnTypeProvider/VersionCompareReturnTypeProvider.php +++ b/src/Psalm/Internal/Provider/ReturnTypeProvider/VersionCompareReturnTypeProvider.php @@ -17,7 +17,7 @@ /** * @internal */ -class VersionCompareReturnTypeProvider implements FunctionReturnTypeProviderInterface +final class VersionCompareReturnTypeProvider implements FunctionReturnTypeProviderInterface { /** * @return array diff --git a/src/Psalm/Internal/Provider/StatementsProvider.php b/src/Psalm/Internal/Provider/StatementsProvider.php index 21bccd1c35c..bd8e34a4b8c 100644 --- a/src/Psalm/Internal/Provider/StatementsProvider.php +++ b/src/Psalm/Internal/Provider/StatementsProvider.php @@ -39,7 +39,7 @@ /** * @internal */ -class StatementsProvider +final class StatementsProvider { private FileProvider $file_provider; diff --git a/src/Psalm/Internal/ReferenceConstraint.php b/src/Psalm/Internal/ReferenceConstraint.php index 64db0e24344..74bfb4eef88 100644 --- a/src/Psalm/Internal/ReferenceConstraint.php +++ b/src/Psalm/Internal/ReferenceConstraint.php @@ -10,7 +10,7 @@ /** * @internal */ -class ReferenceConstraint +final class ReferenceConstraint { public ?Union $type = null; diff --git a/src/Psalm/Internal/Scanner/ClassLikeDocblockComment.php b/src/Psalm/Internal/Scanner/ClassLikeDocblockComment.php index 0d68ece0f25..77a14ec379d 100644 --- a/src/Psalm/Internal/Scanner/ClassLikeDocblockComment.php +++ b/src/Psalm/Internal/Scanner/ClassLikeDocblockComment.php @@ -7,7 +7,7 @@ /** * @internal */ -class ClassLikeDocblockComment +final class ClassLikeDocblockComment { /** * Whether or not the class is deprecated diff --git a/src/Psalm/Internal/Scanner/DocblockParser.php b/src/Psalm/Internal/Scanner/DocblockParser.php index 0c052346bef..52459acbed8 100644 --- a/src/Psalm/Internal/Scanner/DocblockParser.php +++ b/src/Psalm/Internal/Scanner/DocblockParser.php @@ -31,7 +31,7 @@ * * @internal */ -class DocblockParser +final class DocblockParser { /** * $offsetStart is the absolute position of the docblock in the file. It'll be used to add to the position of some diff --git a/src/Psalm/Internal/Scanner/FunctionDocblockComment.php b/src/Psalm/Internal/Scanner/FunctionDocblockComment.php index 400dbcc6904..959cfb3231f 100644 --- a/src/Psalm/Internal/Scanner/FunctionDocblockComment.php +++ b/src/Psalm/Internal/Scanner/FunctionDocblockComment.php @@ -5,7 +5,7 @@ /** * @internal */ -class FunctionDocblockComment +final class FunctionDocblockComment { public ?string $return_type = null; diff --git a/src/Psalm/Internal/Scanner/ParsedDocblock.php b/src/Psalm/Internal/Scanner/ParsedDocblock.php index 1e5b0f89692..bdd18f429d0 100644 --- a/src/Psalm/Internal/Scanner/ParsedDocblock.php +++ b/src/Psalm/Internal/Scanner/ParsedDocblock.php @@ -8,7 +8,7 @@ /** * @internal */ -class ParsedDocblock +final class ParsedDocblock { public string $description; diff --git a/src/Psalm/Internal/Scanner/PhpStormMetaScanner.php b/src/Psalm/Internal/Scanner/PhpStormMetaScanner.php index b812456d7af..6058c39ccbd 100644 --- a/src/Psalm/Internal/Scanner/PhpStormMetaScanner.php +++ b/src/Psalm/Internal/Scanner/PhpStormMetaScanner.php @@ -23,7 +23,7 @@ /** * @internal */ -class PhpStormMetaScanner +final class PhpStormMetaScanner { /** * @param list $args diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/ArrayOffsetFetch.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/ArrayOffsetFetch.php index dcff9097691..7efbfb48c77 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/ArrayOffsetFetch.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/ArrayOffsetFetch.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class ArrayOffsetFetch extends UnresolvedConstantComponent +final class ArrayOffsetFetch extends UnresolvedConstantComponent { public UnresolvedConstantComponent $array; diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/ArraySpread.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/ArraySpread.php index 7078bdcc671..ef8c443d7ba 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/ArraySpread.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/ArraySpread.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class ArraySpread extends UnresolvedConstantComponent +final class ArraySpread extends UnresolvedConstantComponent { public UnresolvedConstantComponent $array; diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/ArrayValue.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/ArrayValue.php index eb56c44533b..6fc943daa79 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/ArrayValue.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/ArrayValue.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class ArrayValue extends UnresolvedConstantComponent +final class ArrayValue extends UnresolvedConstantComponent { /** @var array */ public array $entries; diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/ClassConstant.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/ClassConstant.php index e75bd93b318..101c18a48ea 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/ClassConstant.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/ClassConstant.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class ClassConstant extends UnresolvedConstantComponent +final class ClassConstant extends UnresolvedConstantComponent { public string $fqcln; diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/Constant.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/Constant.php index f7363e5dafc..45c36ee7bf7 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/Constant.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/Constant.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class Constant extends UnresolvedConstantComponent +final class Constant extends UnresolvedConstantComponent { public string $name; diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/EnumNameFetch.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/EnumNameFetch.php index 29639fb3ceb..5b56cc696ed 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/EnumNameFetch.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/EnumNameFetch.php @@ -6,6 +6,6 @@ * @psalm-immutable * @internal */ -class EnumNameFetch extends EnumPropertyFetch +final class EnumNameFetch extends EnumPropertyFetch { } diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/EnumValueFetch.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/EnumValueFetch.php index 1ee9c003dd8..4387213787b 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/EnumValueFetch.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/EnumValueFetch.php @@ -6,6 +6,6 @@ * @psalm-immutable * @internal */ -class EnumValueFetch extends EnumPropertyFetch +final class EnumValueFetch extends EnumPropertyFetch { } diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/KeyValuePair.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/KeyValuePair.php index 607bc7a58f8..adb980ed4db 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/KeyValuePair.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/KeyValuePair.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class KeyValuePair extends UnresolvedConstantComponent +final class KeyValuePair extends UnresolvedConstantComponent { public ?UnresolvedConstantComponent $key = null; diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/ScalarValue.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/ScalarValue.php index 688387ef6c1..6e1f292cec9 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/ScalarValue.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/ScalarValue.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class ScalarValue extends UnresolvedConstantComponent +final class ScalarValue extends UnresolvedConstantComponent { /** @var string|int|float|bool|null */ public $value; diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedAdditionOp.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedAdditionOp.php index 64c33e5874f..21637ee839f 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedAdditionOp.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedAdditionOp.php @@ -6,6 +6,6 @@ * @psalm-immutable * @internal */ -class UnresolvedAdditionOp extends UnresolvedBinaryOp +final class UnresolvedAdditionOp extends UnresolvedBinaryOp { } diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseAnd.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseAnd.php index bbd471f08e7..1b8e4ae018b 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseAnd.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseAnd.php @@ -6,6 +6,6 @@ * @psalm-immutable * @internal */ -class UnresolvedBitwiseAnd extends UnresolvedBinaryOp +final class UnresolvedBitwiseAnd extends UnresolvedBinaryOp { } diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseOr.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseOr.php index 6995432d1fe..9b2956d12c0 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseOr.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseOr.php @@ -6,6 +6,6 @@ * @psalm-immutable * @internal */ -class UnresolvedBitwiseOr extends UnresolvedBinaryOp +final class UnresolvedBitwiseOr extends UnresolvedBinaryOp { } diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseXor.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseXor.php index d2070eb941e..62102caf69e 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseXor.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedBitwiseXor.php @@ -6,6 +6,6 @@ * @psalm-immutable * @internal */ -class UnresolvedBitwiseXor extends UnresolvedBinaryOp +final class UnresolvedBitwiseXor extends UnresolvedBinaryOp { } diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedConcatOp.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedConcatOp.php index 2d7910ead63..bd8b9671411 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedConcatOp.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedConcatOp.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class UnresolvedConcatOp extends UnresolvedBinaryOp +final class UnresolvedConcatOp extends UnresolvedBinaryOp { use ImmutableNonCloneableTrait; } diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedDivisionOp.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedDivisionOp.php index 00ee1dd6be8..27c83dad87c 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedDivisionOp.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedDivisionOp.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class UnresolvedDivisionOp extends UnresolvedBinaryOp +final class UnresolvedDivisionOp extends UnresolvedBinaryOp { use ImmutableNonCloneableTrait; } diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedMultiplicationOp.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedMultiplicationOp.php index f167d9d8fc7..fdfde38ef66 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedMultiplicationOp.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedMultiplicationOp.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class UnresolvedMultiplicationOp extends UnresolvedBinaryOp +final class UnresolvedMultiplicationOp extends UnresolvedBinaryOp { use ImmutableNonCloneableTrait; } diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedSubtractionOp.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedSubtractionOp.php index 2b111f3aeda..26096d7b81a 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedSubtractionOp.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedSubtractionOp.php @@ -8,7 +8,7 @@ * @psalm-immutable * @internal */ -class UnresolvedSubtractionOp extends UnresolvedBinaryOp +final class UnresolvedSubtractionOp extends UnresolvedBinaryOp { use ImmutableNonCloneableTrait; } diff --git a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedTernary.php b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedTernary.php index 294b129e01c..8a2acf839ae 100644 --- a/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedTernary.php +++ b/src/Psalm/Internal/Scanner/UnresolvedConstant/UnresolvedTernary.php @@ -9,7 +9,7 @@ * @psalm-immutable * @internal */ -class UnresolvedTernary extends UnresolvedConstantComponent +final class UnresolvedTernary extends UnresolvedConstantComponent { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/Scanner/VarDocblockComment.php b/src/Psalm/Internal/Scanner/VarDocblockComment.php index 4a1651c9044..15150bd0ced 100644 --- a/src/Psalm/Internal/Scanner/VarDocblockComment.php +++ b/src/Psalm/Internal/Scanner/VarDocblockComment.php @@ -7,7 +7,7 @@ /** * @internal */ -class VarDocblockComment +final class VarDocblockComment { public ?Union $type = null; diff --git a/src/Psalm/Internal/Scope/CaseScope.php b/src/Psalm/Internal/Scope/CaseScope.php index a96832f4eff..7bc396f1ca7 100644 --- a/src/Psalm/Internal/Scope/CaseScope.php +++ b/src/Psalm/Internal/Scope/CaseScope.php @@ -8,7 +8,7 @@ /** * @internal */ -class CaseScope +final class CaseScope { public Context $parent_context; diff --git a/src/Psalm/Internal/Scope/FinallyScope.php b/src/Psalm/Internal/Scope/FinallyScope.php index 4fcda32379f..816ed49904e 100644 --- a/src/Psalm/Internal/Scope/FinallyScope.php +++ b/src/Psalm/Internal/Scope/FinallyScope.php @@ -7,7 +7,7 @@ /** * @internal */ -class FinallyScope +final class FinallyScope { /** * @var array diff --git a/src/Psalm/Internal/Scope/IfConditionalScope.php b/src/Psalm/Internal/Scope/IfConditionalScope.php index 5d7579c594e..acd923a58f7 100644 --- a/src/Psalm/Internal/Scope/IfConditionalScope.php +++ b/src/Psalm/Internal/Scope/IfConditionalScope.php @@ -8,7 +8,7 @@ /** * @internal */ -class IfConditionalScope +final class IfConditionalScope { public Context $if_context; diff --git a/src/Psalm/Internal/Scope/IfScope.php b/src/Psalm/Internal/Scope/IfScope.php index 27a5181d970..4d75ee24462 100644 --- a/src/Psalm/Internal/Scope/IfScope.php +++ b/src/Psalm/Internal/Scope/IfScope.php @@ -10,7 +10,7 @@ /** * @internal */ -class IfScope +final class IfScope { /** * @var array|null diff --git a/src/Psalm/Internal/Scope/LoopScope.php b/src/Psalm/Internal/Scope/LoopScope.php index 1eb1fa0026e..76b059329f1 100644 --- a/src/Psalm/Internal/Scope/LoopScope.php +++ b/src/Psalm/Internal/Scope/LoopScope.php @@ -8,7 +8,7 @@ /** * @internal */ -class LoopScope +final class LoopScope { public int $iteration_count = 0; diff --git a/src/Psalm/Internal/Scope/SwitchScope.php b/src/Psalm/Internal/Scope/SwitchScope.php index 64937c78ae3..c5f5938ebf1 100644 --- a/src/Psalm/Internal/Scope/SwitchScope.php +++ b/src/Psalm/Internal/Scope/SwitchScope.php @@ -9,7 +9,7 @@ /** * @internal */ -class SwitchScope +final class SwitchScope { /** * @var array|null diff --git a/src/Psalm/Internal/Stubs/Generator/ClassLikeStubGenerator.php b/src/Psalm/Internal/Stubs/Generator/ClassLikeStubGenerator.php index 4ea25eabbe6..58888f21df9 100644 --- a/src/Psalm/Internal/Stubs/Generator/ClassLikeStubGenerator.php +++ b/src/Psalm/Internal/Stubs/Generator/ClassLikeStubGenerator.php @@ -28,7 +28,7 @@ /** * @internal */ -class ClassLikeStubGenerator +final class ClassLikeStubGenerator { /** * @return PhpParser\Node\Stmt\Class_|PhpParser\Node\Stmt\Interface_|PhpParser\Node\Stmt\Trait_ diff --git a/src/Psalm/Internal/Stubs/Generator/StubsGenerator.php b/src/Psalm/Internal/Stubs/Generator/StubsGenerator.php index df5c8d40e7e..95909902309 100644 --- a/src/Psalm/Internal/Stubs/Generator/StubsGenerator.php +++ b/src/Psalm/Internal/Stubs/Generator/StubsGenerator.php @@ -51,7 +51,7 @@ /** * @internal */ -class StubsGenerator +final class StubsGenerator { public static function getAll( Codebase $codebase, diff --git a/src/Psalm/Internal/Type/ArrayType.php b/src/Psalm/Internal/Type/ArrayType.php index c9e1d17acf7..f115fcc9879 100644 --- a/src/Psalm/Internal/Type/ArrayType.php +++ b/src/Psalm/Internal/Type/ArrayType.php @@ -15,7 +15,7 @@ /** * @internal */ -class ArrayType +final class ArrayType { public Union $key; diff --git a/src/Psalm/Internal/Type/AssertionReconciler.php b/src/Psalm/Internal/Type/AssertionReconciler.php index 85410c4c09c..d82a5c07384 100644 --- a/src/Psalm/Internal/Type/AssertionReconciler.php +++ b/src/Psalm/Internal/Type/AssertionReconciler.php @@ -68,7 +68,7 @@ /** * @internal */ -class AssertionReconciler extends Reconciler +final class AssertionReconciler extends Reconciler { /** * Reconciles types diff --git a/src/Psalm/Internal/Type/Comparator/ArrayTypeComparator.php b/src/Psalm/Internal/Type/Comparator/ArrayTypeComparator.php index 6977e465876..c440526fea5 100644 --- a/src/Psalm/Internal/Type/Comparator/ArrayTypeComparator.php +++ b/src/Psalm/Internal/Type/Comparator/ArrayTypeComparator.php @@ -16,7 +16,7 @@ /** * @internal */ -class ArrayTypeComparator +final class ArrayTypeComparator { /** * @param TArray|TKeyedArray|TClassStringMap $input_type_part diff --git a/src/Psalm/Internal/Type/Comparator/AtomicTypeComparator.php b/src/Psalm/Internal/Type/Comparator/AtomicTypeComparator.php index 26516c0a9e3..0b3478ea978 100644 --- a/src/Psalm/Internal/Type/Comparator/AtomicTypeComparator.php +++ b/src/Psalm/Internal/Type/Comparator/AtomicTypeComparator.php @@ -48,7 +48,7 @@ /** * @internal */ -class AtomicTypeComparator +final class AtomicTypeComparator { /** * Does the input param atomic type match the given param atomic type diff --git a/src/Psalm/Internal/Type/Comparator/CallableTypeComparator.php b/src/Psalm/Internal/Type/Comparator/CallableTypeComparator.php index 2999480dd36..855445fadd0 100644 --- a/src/Psalm/Internal/Type/Comparator/CallableTypeComparator.php +++ b/src/Psalm/Internal/Type/Comparator/CallableTypeComparator.php @@ -37,7 +37,7 @@ /** * @internal */ -class CallableTypeComparator +final class CallableTypeComparator { /** * @param TCallable|TClosure $input_type_part diff --git a/src/Psalm/Internal/Type/Comparator/ClassLikeStringComparator.php b/src/Psalm/Internal/Type/Comparator/ClassLikeStringComparator.php index a3830ea83d4..0fe514cc300 100644 --- a/src/Psalm/Internal/Type/Comparator/ClassLikeStringComparator.php +++ b/src/Psalm/Internal/Type/Comparator/ClassLikeStringComparator.php @@ -14,7 +14,7 @@ /** * @internal */ -class ClassLikeStringComparator +final class ClassLikeStringComparator { /** * @param TClassString|TLiteralClassString $input_type_part diff --git a/src/Psalm/Internal/Type/Comparator/GenericTypeComparator.php b/src/Psalm/Internal/Type/Comparator/GenericTypeComparator.php index 964ffdf0828..fe91a3bc003 100644 --- a/src/Psalm/Internal/Type/Comparator/GenericTypeComparator.php +++ b/src/Psalm/Internal/Type/Comparator/GenericTypeComparator.php @@ -12,7 +12,7 @@ /** * @internal */ -class GenericTypeComparator +final class GenericTypeComparator { /** * @param TGenericObject|TIterable $container_type_part diff --git a/src/Psalm/Internal/Type/Comparator/IntegerRangeComparator.php b/src/Psalm/Internal/Type/Comparator/IntegerRangeComparator.php index e462143b563..3263efdb78b 100644 --- a/src/Psalm/Internal/Type/Comparator/IntegerRangeComparator.php +++ b/src/Psalm/Internal/Type/Comparator/IntegerRangeComparator.php @@ -16,7 +16,7 @@ /** * @internal */ -class IntegerRangeComparator +final class IntegerRangeComparator { /** * This method is used to check if an integer range can be contained in another diff --git a/src/Psalm/Internal/Type/Comparator/KeyedArrayComparator.php b/src/Psalm/Internal/Type/Comparator/KeyedArrayComparator.php index c9d7aad5842..1fad958847d 100644 --- a/src/Psalm/Internal/Type/Comparator/KeyedArrayComparator.php +++ b/src/Psalm/Internal/Type/Comparator/KeyedArrayComparator.php @@ -19,7 +19,7 @@ /** * @internal */ -class KeyedArrayComparator +final class KeyedArrayComparator { /** * @param TKeyedArray|TObjectWithProperties $input_type_part diff --git a/src/Psalm/Internal/Type/Comparator/ObjectComparator.php b/src/Psalm/Internal/Type/Comparator/ObjectComparator.php index 1d264658dd8..88b239efb06 100644 --- a/src/Psalm/Internal/Type/Comparator/ObjectComparator.php +++ b/src/Psalm/Internal/Type/Comparator/ObjectComparator.php @@ -23,7 +23,7 @@ /** * @internal */ -class ObjectComparator +final class ObjectComparator { /** * @param TNamedObject|TTemplateParam|TIterable $input_type_part diff --git a/src/Psalm/Internal/Type/Comparator/ScalarTypeComparator.php b/src/Psalm/Internal/Type/Comparator/ScalarTypeComparator.php index b8941667156..c688407cad6 100644 --- a/src/Psalm/Internal/Type/Comparator/ScalarTypeComparator.php +++ b/src/Psalm/Internal/Type/Comparator/ScalarTypeComparator.php @@ -45,7 +45,7 @@ /** * @internal */ -class ScalarTypeComparator +final class ScalarTypeComparator { public static function isContainedBy( Codebase $codebase, diff --git a/src/Psalm/Internal/Type/Comparator/TypeComparisonResult.php b/src/Psalm/Internal/Type/Comparator/TypeComparisonResult.php index 284d946b591..3933881fd76 100644 --- a/src/Psalm/Internal/Type/Comparator/TypeComparisonResult.php +++ b/src/Psalm/Internal/Type/Comparator/TypeComparisonResult.php @@ -8,7 +8,7 @@ /** * @internal */ -class TypeComparisonResult +final class TypeComparisonResult { /** * This is used to trigger `InvalidScalarArgument` in situations where we know PHP diff --git a/src/Psalm/Internal/Type/Comparator/UnionTypeComparator.php b/src/Psalm/Internal/Type/Comparator/UnionTypeComparator.php index d3c1b457322..7a22dc87325 100644 --- a/src/Psalm/Internal/Type/Comparator/UnionTypeComparator.php +++ b/src/Psalm/Internal/Type/Comparator/UnionTypeComparator.php @@ -29,7 +29,7 @@ /** * @internal */ -class UnionTypeComparator +final class UnionTypeComparator { /** * Does the input param type match the given param type diff --git a/src/Psalm/Internal/Type/NegatedAssertionReconciler.php b/src/Psalm/Internal/Type/NegatedAssertionReconciler.php index ab7da873005..af2b84b2764 100644 --- a/src/Psalm/Internal/Type/NegatedAssertionReconciler.php +++ b/src/Psalm/Internal/Type/NegatedAssertionReconciler.php @@ -41,7 +41,7 @@ /** * @internal */ -class NegatedAssertionReconciler extends Reconciler +final class NegatedAssertionReconciler extends Reconciler { /** * @param string[] $suppressed_issues diff --git a/src/Psalm/Internal/Type/ParseTree/CallableParamTree.php b/src/Psalm/Internal/Type/ParseTree/CallableParamTree.php index 4154483e76f..53bc98bbbc8 100644 --- a/src/Psalm/Internal/Type/ParseTree/CallableParamTree.php +++ b/src/Psalm/Internal/Type/ParseTree/CallableParamTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class CallableParamTree extends ParseTree +final class CallableParamTree extends ParseTree { public bool $variadic = false; diff --git a/src/Psalm/Internal/Type/ParseTree/CallableTree.php b/src/Psalm/Internal/Type/ParseTree/CallableTree.php index 5f3c64014cc..f249d06e88e 100644 --- a/src/Psalm/Internal/Type/ParseTree/CallableTree.php +++ b/src/Psalm/Internal/Type/ParseTree/CallableTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class CallableTree extends ParseTree +final class CallableTree extends ParseTree { public string $value; diff --git a/src/Psalm/Internal/Type/ParseTree/CallableWithReturnTypeTree.php b/src/Psalm/Internal/Type/ParseTree/CallableWithReturnTypeTree.php index 3069d73681c..a1dc3798253 100644 --- a/src/Psalm/Internal/Type/ParseTree/CallableWithReturnTypeTree.php +++ b/src/Psalm/Internal/Type/ParseTree/CallableWithReturnTypeTree.php @@ -7,6 +7,6 @@ /** * @internal */ -class CallableWithReturnTypeTree extends ParseTree +final class CallableWithReturnTypeTree extends ParseTree { } diff --git a/src/Psalm/Internal/Type/ParseTree/ConditionalTree.php b/src/Psalm/Internal/Type/ParseTree/ConditionalTree.php index 786d1ca07b9..cada2a61c45 100644 --- a/src/Psalm/Internal/Type/ParseTree/ConditionalTree.php +++ b/src/Psalm/Internal/Type/ParseTree/ConditionalTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class ConditionalTree extends ParseTree +final class ConditionalTree extends ParseTree { public TemplateIsTree $condition; diff --git a/src/Psalm/Internal/Type/ParseTree/EncapsulationTree.php b/src/Psalm/Internal/Type/ParseTree/EncapsulationTree.php index 63fc3e0fafb..45027ce5ec3 100644 --- a/src/Psalm/Internal/Type/ParseTree/EncapsulationTree.php +++ b/src/Psalm/Internal/Type/ParseTree/EncapsulationTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class EncapsulationTree extends ParseTree +final class EncapsulationTree extends ParseTree { public bool $terminated = false; } diff --git a/src/Psalm/Internal/Type/ParseTree/FieldEllipsis.php b/src/Psalm/Internal/Type/ParseTree/FieldEllipsis.php index 8ec2156c599..58f6fcf79bb 100644 --- a/src/Psalm/Internal/Type/ParseTree/FieldEllipsis.php +++ b/src/Psalm/Internal/Type/ParseTree/FieldEllipsis.php @@ -7,6 +7,6 @@ /** * @internal */ -class FieldEllipsis extends ParseTree +final class FieldEllipsis extends ParseTree { } diff --git a/src/Psalm/Internal/Type/ParseTree/GenericTree.php b/src/Psalm/Internal/Type/ParseTree/GenericTree.php index cefe8e4bb66..9b84271d06d 100644 --- a/src/Psalm/Internal/Type/ParseTree/GenericTree.php +++ b/src/Psalm/Internal/Type/ParseTree/GenericTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class GenericTree extends ParseTree +final class GenericTree extends ParseTree { public string $value; diff --git a/src/Psalm/Internal/Type/ParseTree/IndexedAccessTree.php b/src/Psalm/Internal/Type/ParseTree/IndexedAccessTree.php index c50f401d343..fdaa1e98cfc 100644 --- a/src/Psalm/Internal/Type/ParseTree/IndexedAccessTree.php +++ b/src/Psalm/Internal/Type/ParseTree/IndexedAccessTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class IndexedAccessTree extends ParseTree +final class IndexedAccessTree extends ParseTree { public string $value; diff --git a/src/Psalm/Internal/Type/ParseTree/IntersectionTree.php b/src/Psalm/Internal/Type/ParseTree/IntersectionTree.php index 7025160753e..f7bea8dbfb5 100644 --- a/src/Psalm/Internal/Type/ParseTree/IntersectionTree.php +++ b/src/Psalm/Internal/Type/ParseTree/IntersectionTree.php @@ -7,6 +7,6 @@ /** * @internal */ -class IntersectionTree extends ParseTree +final class IntersectionTree extends ParseTree { } diff --git a/src/Psalm/Internal/Type/ParseTree/KeyedArrayPropertyTree.php b/src/Psalm/Internal/Type/ParseTree/KeyedArrayPropertyTree.php index ba17ccfc1dd..443275f6100 100644 --- a/src/Psalm/Internal/Type/ParseTree/KeyedArrayPropertyTree.php +++ b/src/Psalm/Internal/Type/ParseTree/KeyedArrayPropertyTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class KeyedArrayPropertyTree extends ParseTree +final class KeyedArrayPropertyTree extends ParseTree { public string $value; diff --git a/src/Psalm/Internal/Type/ParseTree/KeyedArrayTree.php b/src/Psalm/Internal/Type/ParseTree/KeyedArrayTree.php index 90c1249bd1b..f3ec3e4fe89 100644 --- a/src/Psalm/Internal/Type/ParseTree/KeyedArrayTree.php +++ b/src/Psalm/Internal/Type/ParseTree/KeyedArrayTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class KeyedArrayTree extends ParseTree +final class KeyedArrayTree extends ParseTree { public string $value; diff --git a/src/Psalm/Internal/Type/ParseTree/MethodParamTree.php b/src/Psalm/Internal/Type/ParseTree/MethodParamTree.php index 82f8bd80a01..39237a1b9d2 100644 --- a/src/Psalm/Internal/Type/ParseTree/MethodParamTree.php +++ b/src/Psalm/Internal/Type/ParseTree/MethodParamTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class MethodParamTree extends ParseTree +final class MethodParamTree extends ParseTree { public bool $variadic; diff --git a/src/Psalm/Internal/Type/ParseTree/MethodTree.php b/src/Psalm/Internal/Type/ParseTree/MethodTree.php index f77494b405c..12f800c565e 100644 --- a/src/Psalm/Internal/Type/ParseTree/MethodTree.php +++ b/src/Psalm/Internal/Type/ParseTree/MethodTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class MethodTree extends ParseTree +final class MethodTree extends ParseTree { public string $value; diff --git a/src/Psalm/Internal/Type/ParseTree/MethodWithReturnTypeTree.php b/src/Psalm/Internal/Type/ParseTree/MethodWithReturnTypeTree.php index 47701b3ce7c..ed81373f73b 100644 --- a/src/Psalm/Internal/Type/ParseTree/MethodWithReturnTypeTree.php +++ b/src/Psalm/Internal/Type/ParseTree/MethodWithReturnTypeTree.php @@ -7,6 +7,6 @@ /** * @internal */ -class MethodWithReturnTypeTree extends ParseTree +final class MethodWithReturnTypeTree extends ParseTree { } diff --git a/src/Psalm/Internal/Type/ParseTree/NullableTree.php b/src/Psalm/Internal/Type/ParseTree/NullableTree.php index 2471184da64..8a18e12b0ac 100644 --- a/src/Psalm/Internal/Type/ParseTree/NullableTree.php +++ b/src/Psalm/Internal/Type/ParseTree/NullableTree.php @@ -7,6 +7,6 @@ /** * @internal */ -class NullableTree extends ParseTree +final class NullableTree extends ParseTree { } diff --git a/src/Psalm/Internal/Type/ParseTree/Root.php b/src/Psalm/Internal/Type/ParseTree/Root.php index b08f963480f..35aefa0b108 100644 --- a/src/Psalm/Internal/Type/ParseTree/Root.php +++ b/src/Psalm/Internal/Type/ParseTree/Root.php @@ -7,6 +7,6 @@ /** * @internal */ -class Root extends ParseTree +final class Root extends ParseTree { } diff --git a/src/Psalm/Internal/Type/ParseTree/TemplateAsTree.php b/src/Psalm/Internal/Type/ParseTree/TemplateAsTree.php index bb5de0c72b6..f350184f2b9 100644 --- a/src/Psalm/Internal/Type/ParseTree/TemplateAsTree.php +++ b/src/Psalm/Internal/Type/ParseTree/TemplateAsTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class TemplateAsTree extends ParseTree +final class TemplateAsTree extends ParseTree { public string $param_name; diff --git a/src/Psalm/Internal/Type/ParseTree/TemplateIsTree.php b/src/Psalm/Internal/Type/ParseTree/TemplateIsTree.php index 4ad27411daf..2cc6c06e3ac 100644 --- a/src/Psalm/Internal/Type/ParseTree/TemplateIsTree.php +++ b/src/Psalm/Internal/Type/ParseTree/TemplateIsTree.php @@ -7,7 +7,7 @@ /** * @internal */ -class TemplateIsTree extends ParseTree +final class TemplateIsTree extends ParseTree { public string $param_name; diff --git a/src/Psalm/Internal/Type/ParseTree/UnionTree.php b/src/Psalm/Internal/Type/ParseTree/UnionTree.php index 1f8de487211..93f6195fcb5 100644 --- a/src/Psalm/Internal/Type/ParseTree/UnionTree.php +++ b/src/Psalm/Internal/Type/ParseTree/UnionTree.php @@ -7,6 +7,6 @@ /** * @internal */ -class UnionTree extends ParseTree +final class UnionTree extends ParseTree { } diff --git a/src/Psalm/Internal/Type/ParseTree/Value.php b/src/Psalm/Internal/Type/ParseTree/Value.php index e61d14efbe6..1f9a506f42f 100644 --- a/src/Psalm/Internal/Type/ParseTree/Value.php +++ b/src/Psalm/Internal/Type/ParseTree/Value.php @@ -7,7 +7,7 @@ /** * @internal */ -class Value extends ParseTree +final class Value extends ParseTree { public string $value; diff --git a/src/Psalm/Internal/Type/ParseTreeCreator.php b/src/Psalm/Internal/Type/ParseTreeCreator.php index 0ea26080433..b9b7368d34e 100644 --- a/src/Psalm/Internal/Type/ParseTreeCreator.php +++ b/src/Psalm/Internal/Type/ParseTreeCreator.php @@ -34,7 +34,7 @@ /** * @internal */ -class ParseTreeCreator +final class ParseTreeCreator { private ParseTree $parse_tree; diff --git a/src/Psalm/Internal/Type/SimpleAssertionReconciler.php b/src/Psalm/Internal/Type/SimpleAssertionReconciler.php index aa606ec8f89..f63100c49aa 100644 --- a/src/Psalm/Internal/Type/SimpleAssertionReconciler.php +++ b/src/Psalm/Internal/Type/SimpleAssertionReconciler.php @@ -97,7 +97,7 @@ * * @internal */ -class SimpleAssertionReconciler extends Reconciler +final class SimpleAssertionReconciler extends Reconciler { /** * @param string[] $suppressed_issues diff --git a/src/Psalm/Internal/Type/SimpleNegatedAssertionReconciler.php b/src/Psalm/Internal/Type/SimpleNegatedAssertionReconciler.php index 160bdc7482f..06d654ec1c2 100644 --- a/src/Psalm/Internal/Type/SimpleNegatedAssertionReconciler.php +++ b/src/Psalm/Internal/Type/SimpleNegatedAssertionReconciler.php @@ -68,7 +68,7 @@ /** * @internal */ -class SimpleNegatedAssertionReconciler extends Reconciler +final class SimpleNegatedAssertionReconciler extends Reconciler { /** * @param string[] $suppressed_issues diff --git a/src/Psalm/Internal/Type/TemplateBound.php b/src/Psalm/Internal/Type/TemplateBound.php index 01aada21077..71e219afa43 100644 --- a/src/Psalm/Internal/Type/TemplateBound.php +++ b/src/Psalm/Internal/Type/TemplateBound.php @@ -7,7 +7,7 @@ /** * @internal */ -class TemplateBound +final class TemplateBound { public Union $type; diff --git a/src/Psalm/Internal/Type/TemplateInferredTypeReplacer.php b/src/Psalm/Internal/Type/TemplateInferredTypeReplacer.php index 259aedd9521..ab367ca66c8 100644 --- a/src/Psalm/Internal/Type/TemplateInferredTypeReplacer.php +++ b/src/Psalm/Internal/Type/TemplateInferredTypeReplacer.php @@ -38,7 +38,7 @@ /** * @internal */ -class TemplateInferredTypeReplacer +final class TemplateInferredTypeReplacer { /** * This replaces template types in unions with the inferred types they should be diff --git a/src/Psalm/Internal/Type/TemplateResult.php b/src/Psalm/Internal/Type/TemplateResult.php index 72a7a05cd5e..a759e4f5507 100644 --- a/src/Psalm/Internal/Type/TemplateResult.php +++ b/src/Psalm/Internal/Type/TemplateResult.php @@ -24,7 +24,7 @@ * * @internal */ -class TemplateResult +final class TemplateResult { /** * @var array> diff --git a/src/Psalm/Internal/Type/TemplateStandinTypeReplacer.php b/src/Psalm/Internal/Type/TemplateStandinTypeReplacer.php index bbab4e24b7b..7ce88ebb54c 100644 --- a/src/Psalm/Internal/Type/TemplateStandinTypeReplacer.php +++ b/src/Psalm/Internal/Type/TemplateStandinTypeReplacer.php @@ -53,7 +53,7 @@ /** * @internal */ -class TemplateStandinTypeReplacer +final class TemplateStandinTypeReplacer { /** * This method fills in the values in $template_result based on how the various atomic types diff --git a/src/Psalm/Internal/Type/TypeAlias/ClassTypeAlias.php b/src/Psalm/Internal/Type/TypeAlias/ClassTypeAlias.php index 49267d9924e..d3076affc00 100644 --- a/src/Psalm/Internal/Type/TypeAlias/ClassTypeAlias.php +++ b/src/Psalm/Internal/Type/TypeAlias/ClassTypeAlias.php @@ -8,7 +8,7 @@ /** * @internal */ -class ClassTypeAlias implements TypeAlias +final class ClassTypeAlias implements TypeAlias { /** * @var list diff --git a/src/Psalm/Internal/Type/TypeAlias/InlineTypeAlias.php b/src/Psalm/Internal/Type/TypeAlias/InlineTypeAlias.php index ab49068d4b1..03d09f216fb 100644 --- a/src/Psalm/Internal/Type/TypeAlias/InlineTypeAlias.php +++ b/src/Psalm/Internal/Type/TypeAlias/InlineTypeAlias.php @@ -9,7 +9,7 @@ * @psalm-immutable * @internal */ -class InlineTypeAlias implements TypeAlias +final class InlineTypeAlias implements TypeAlias { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/Type/TypeAlias/LinkableTypeAlias.php b/src/Psalm/Internal/Type/TypeAlias/LinkableTypeAlias.php index 96aa6678936..3eb75ce824c 100644 --- a/src/Psalm/Internal/Type/TypeAlias/LinkableTypeAlias.php +++ b/src/Psalm/Internal/Type/TypeAlias/LinkableTypeAlias.php @@ -9,7 +9,7 @@ * @psalm-immutable * @internal */ -class LinkableTypeAlias implements TypeAlias +final class LinkableTypeAlias implements TypeAlias { use ImmutableNonCloneableTrait; diff --git a/src/Psalm/Internal/Type/TypeCombination.php b/src/Psalm/Internal/Type/TypeCombination.php index 863ae77f932..0706315d1ac 100644 --- a/src/Psalm/Internal/Type/TypeCombination.php +++ b/src/Psalm/Internal/Type/TypeCombination.php @@ -22,7 +22,7 @@ /** * @internal */ -class TypeCombination +final class TypeCombination { /** @var array */ public array $value_types = []; diff --git a/src/Psalm/Internal/Type/TypeCombiner.php b/src/Psalm/Internal/Type/TypeCombiner.php index ee1dd03cd27..3f841da4fa3 100644 --- a/src/Psalm/Internal/Type/TypeCombiner.php +++ b/src/Psalm/Internal/Type/TypeCombiner.php @@ -74,7 +74,7 @@ /** * @internal */ -class TypeCombiner +final class TypeCombiner { /** * Combines types together diff --git a/src/Psalm/Internal/Type/TypeExpander.php b/src/Psalm/Internal/Type/TypeExpander.php index e329f92b632..795b5ad9a8a 100644 --- a/src/Psalm/Internal/Type/TypeExpander.php +++ b/src/Psalm/Internal/Type/TypeExpander.php @@ -51,7 +51,7 @@ /** * @internal */ -class TypeExpander +final class TypeExpander { /** * @psalm-suppress InaccessibleProperty We just created the type diff --git a/src/Psalm/Internal/Type/TypeParser.php b/src/Psalm/Internal/Type/TypeParser.php index 0287ab4d6bd..770e7efc958 100644 --- a/src/Psalm/Internal/Type/TypeParser.php +++ b/src/Psalm/Internal/Type/TypeParser.php @@ -101,7 +101,7 @@ * @psalm-suppress InaccessibleProperty Allowed during construction * @internal */ -class TypeParser +final class TypeParser { /** * Parses a string type representation diff --git a/src/Psalm/Internal/Type/TypeTokenizer.php b/src/Psalm/Internal/Type/TypeTokenizer.php index 66e463e4ccd..ce0660972dd 100644 --- a/src/Psalm/Internal/Type/TypeTokenizer.php +++ b/src/Psalm/Internal/Type/TypeTokenizer.php @@ -22,7 +22,7 @@ /** * @internal */ -class TypeTokenizer +final class TypeTokenizer { /** * @var array diff --git a/src/Psalm/Internal/TypeVisitor/CanContainObjectTypeVisitor.php b/src/Psalm/Internal/TypeVisitor/CanContainObjectTypeVisitor.php index b107ba2eaa0..0dee9e263a9 100644 --- a/src/Psalm/Internal/TypeVisitor/CanContainObjectTypeVisitor.php +++ b/src/Psalm/Internal/TypeVisitor/CanContainObjectTypeVisitor.php @@ -10,7 +10,7 @@ use Psalm\Type\Union; /** @internal */ -class CanContainObjectTypeVisitor extends TypeVisitor +final class CanContainObjectTypeVisitor extends TypeVisitor { private bool $contains_object_type = false; diff --git a/src/Psalm/Internal/TypeVisitor/ClasslikeReplacer.php b/src/Psalm/Internal/TypeVisitor/ClasslikeReplacer.php index 576f647cd3e..ce54f8959b0 100644 --- a/src/Psalm/Internal/TypeVisitor/ClasslikeReplacer.php +++ b/src/Psalm/Internal/TypeVisitor/ClasslikeReplacer.php @@ -14,7 +14,7 @@ /** * @internal */ -class ClasslikeReplacer extends MutableTypeVisitor +final class ClasslikeReplacer extends MutableTypeVisitor { private string $old; private string $new; diff --git a/src/Psalm/Internal/TypeVisitor/ContainsClassLikeVisitor.php b/src/Psalm/Internal/TypeVisitor/ContainsClassLikeVisitor.php index faedea36d6d..7a93f182713 100644 --- a/src/Psalm/Internal/TypeVisitor/ContainsClassLikeVisitor.php +++ b/src/Psalm/Internal/TypeVisitor/ContainsClassLikeVisitor.php @@ -13,7 +13,7 @@ /** * @internal */ -class ContainsClassLikeVisitor extends TypeVisitor +final class ContainsClassLikeVisitor extends TypeVisitor { /** * @var lowercase-string diff --git a/src/Psalm/Internal/TypeVisitor/ContainsLiteralVisitor.php b/src/Psalm/Internal/TypeVisitor/ContainsLiteralVisitor.php index e2358063480..dfb3367740b 100644 --- a/src/Psalm/Internal/TypeVisitor/ContainsLiteralVisitor.php +++ b/src/Psalm/Internal/TypeVisitor/ContainsLiteralVisitor.php @@ -14,7 +14,7 @@ /** * @internal */ -class ContainsLiteralVisitor extends TypeVisitor +final class ContainsLiteralVisitor extends TypeVisitor { private bool $contains_literal = false; diff --git a/src/Psalm/Internal/TypeVisitor/ContainsStaticVisitor.php b/src/Psalm/Internal/TypeVisitor/ContainsStaticVisitor.php index c8ef3fdd8a4..1465381a83c 100644 --- a/src/Psalm/Internal/TypeVisitor/ContainsStaticVisitor.php +++ b/src/Psalm/Internal/TypeVisitor/ContainsStaticVisitor.php @@ -9,7 +9,7 @@ /** * @internal */ -class ContainsStaticVisitor extends TypeVisitor +final class ContainsStaticVisitor extends TypeVisitor { private bool $contains_static = false; diff --git a/src/Psalm/Internal/TypeVisitor/FromDocblockSetter.php b/src/Psalm/Internal/TypeVisitor/FromDocblockSetter.php index 5e624820a9d..189166483c7 100644 --- a/src/Psalm/Internal/TypeVisitor/FromDocblockSetter.php +++ b/src/Psalm/Internal/TypeVisitor/FromDocblockSetter.php @@ -12,7 +12,7 @@ /** * @internal */ -class FromDocblockSetter extends MutableTypeVisitor +final class FromDocblockSetter extends MutableTypeVisitor { private bool $from_docblock; public function __construct(bool $from_docblock) diff --git a/src/Psalm/Internal/TypeVisitor/TemplateTypeCollector.php b/src/Psalm/Internal/TypeVisitor/TemplateTypeCollector.php index a6b2275a466..36db3898416 100644 --- a/src/Psalm/Internal/TypeVisitor/TemplateTypeCollector.php +++ b/src/Psalm/Internal/TypeVisitor/TemplateTypeCollector.php @@ -13,7 +13,7 @@ /** * @internal */ -class TemplateTypeCollector extends TypeVisitor +final class TemplateTypeCollector extends TypeVisitor { /** * @var list diff --git a/src/Psalm/Internal/TypeVisitor/TypeChecker.php b/src/Psalm/Internal/TypeVisitor/TypeChecker.php index 2818b414c16..e55ef5de0cd 100644 --- a/src/Psalm/Internal/TypeVisitor/TypeChecker.php +++ b/src/Psalm/Internal/TypeVisitor/TypeChecker.php @@ -45,7 +45,7 @@ /** * @internal */ -class TypeChecker extends TypeVisitor +final class TypeChecker extends TypeVisitor { private StatementsSource $source; diff --git a/src/Psalm/Internal/TypeVisitor/TypeLocalizer.php b/src/Psalm/Internal/TypeVisitor/TypeLocalizer.php index 81ba6a0eb42..4a2866e93da 100644 --- a/src/Psalm/Internal/TypeVisitor/TypeLocalizer.php +++ b/src/Psalm/Internal/TypeVisitor/TypeLocalizer.php @@ -17,7 +17,7 @@ /** * @internal */ -class TypeLocalizer extends MutableTypeVisitor +final class TypeLocalizer extends MutableTypeVisitor { /** * @var array> diff --git a/src/Psalm/Internal/TypeVisitor/TypeScanner.php b/src/Psalm/Internal/TypeVisitor/TypeScanner.php index d840e7327c2..524044f6358 100644 --- a/src/Psalm/Internal/TypeVisitor/TypeScanner.php +++ b/src/Psalm/Internal/TypeVisitor/TypeScanner.php @@ -15,7 +15,7 @@ /** * @internal */ -class TypeScanner extends TypeVisitor +final class TypeScanner extends TypeVisitor { private Scanner $scanner;