File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -10,9 +10,9 @@ public class FileNameIssueStyleViolationTest
1010
1111        // 正しい名前のフィールド 
1212        private  string  _exampleField  =  "Valid" ; 
13- 
14-         // Staticメンバー配置順序の違反(推奨: 静的要素 → インスタンスメンバーの順序)  
15-          public  static readonly  string  StaticExample  =  "Static Value" ; 
13+         
14+         // スペースが1つ足りない違反  
15+        public  static readonly  string  StaticExample  =  "Static Value" ; 
1616
1717        // メソッド名の命名規則違反(PascalCaseが推奨される) 
1818        public  void  printmessage ( )  // 【違反】PascalCaseでない 
@@ -31,6 +31,12 @@ public void CheckCondition(int value)
3131        { 
3232            if  ( value  >  0 )  // 【違反】波括弧が無い 
3333                Debug . Log ( "Value is positive." ) ; 
34+             
35+             float  x  =  10 ; 
36+             // 【違反】キャストと値の間に空白 
37+             int  y  =  ( int ) x ; 
38+             // 【違反】制御フロー ステートメントのキーワードの後に空白文字を配置 
39+             for  ( var  i = 0 ; i < x ; i ++ )  {  } 
3440        } 
3541
3642        // 正しい条件分岐 
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments