From bda60fea990f678f8a4533a33f652fbfb0a27ab4 Mon Sep 17 00:00:00 2001 From: Johann Beleites Date: Tue, 27 Feb 2024 16:24:58 +0100 Subject: [PATCH] Fix typo in S1171 (#3695) --- rules/S1171/java/rule.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rules/S1171/java/rule.adoc b/rules/S1171/java/rule.adoc index 52132f1d3fd..e83c068bc2d 100644 --- a/rules/S1171/java/rule.adoc +++ b/rules/S1171/java/rule.adoc @@ -1,6 +1,6 @@ == Why is this an issue? -Non-static initializers, also known as instance initializers, are blocks of code within a class that is executed when an instance of the +Non-static initializers, also known as instance initializers, are blocks of code within a class that are executed when an instance of the class is created. They are executed when an object of the class is created just before the constructor is called. Non-static initializers are useful when you want to perform some common initialization logic for all objects of a class. They allow you to initialize instance variables in a concise and centralized manner, without having to repeat the same initialization code in each constructor.