summaryrefslogblamecommitdiff
path: root/test/test12-04.txt
blob: 7da50ed7d0862b64f02bb949be3313c5b23df983 (plain) (tree)
1
2
3
4
5
6
7
8
9
                                                                     
                                                                                  
                                                 

                                                                                  
                                                                                  


                                                                                  
                                                                     
                                                                                  
                                                    
              
                                                                                  
                                                                                  

                                                                                  
                                                                                  
                                                                                  

                                                                                  
                                                                                  
                                                                                  
                                                                                  
                                                                     
                                                                                  
                                                            

                                                                                  
                                                                                  


                                                                                  
                                                                     
                                                                                  

                                              
                                                                                  
                             
                             

                                                                                  
                             
                             
                                                                                  
                                                                     
                                                                                  

                                             

                                                                                  
                                                                     
                                                                                  
                                                              

                                                                                  
                                                                                  


                                                                                  
test12.cpp: In member function 'void Object1::func1(Data1*, Data1*)':
test12.cpp:13:13: warning: Using variable 'ptr2' without checking for null pointer
         int val1 = ptr1 ? ptr1->val : ptr2->val;
             ^
test12.cpp:13:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:13:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:13:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:13:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:13:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp: In member function 'void Object1::func2(Data1*, Data1*)':
test12.cpp:18:13: warning: Using variable 'ptr1' without checking for null pointer
         int val1 = (!ptr1) ? ptr1->val : ptr2->val;
             ^
test12.cpp:18:13: warning: Using variable 'ptr1' without checking for null pointer
test12.cpp:18:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:18:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:18:13: warning: Using variable 'ptr1' without checking for null pointer
test12.cpp:18:13: warning: Using variable 'ptr1' without checking for null pointer
test12.cpp:18:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:18:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:18:13: warning: Using variable 'ptr1' without checking for null pointer
test12.cpp:18:13: warning: Using variable 'ptr1' without checking for null pointer
test12.cpp:18:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:18:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp: In member function 'void Object1::func3(Data1*, Data1*)':
test12.cpp:23:13: warning: Using variable 'ptr2' without checking for null pointer
         int val1 = (ptr1 && !ptr2) ? ptr1->val : ptr2->val;
             ^
test12.cpp:23:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:23:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:23:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:23:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:23:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp: In member function 'void Object1::func4(Data1*, Data1*)':
test12.cpp:28:35: warning: Using variable 'ptr2' without checking for null pointer
         if ((ptr1 ? ptr1 : ptr2)->val == 100)
                                   ^
test12.cpp:30:28: warning: Using variable 'ptr1' without checking for null pointer
             ptr1->val = 200;
                            ^
test12.cpp:30:28: warning: Using variable 'ptr1' without checking for null pointer
test12.cpp:34:28: warning: Using variable 'ptr2' without checking for null pointer
             ptr2->val = 300;
                            ^
test12.cpp:34:28: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp: In member function 'void Object1::func5(Data1*, Data1*)':
test12.cpp:40:41: warning: Using variable 'ptr2' without checking for null pointer
         int tmp = (ptr1 ? ptr1 : ptr2)->val;
                                         ^
test12.cpp:40:41: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:40:41: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp: In member function 'void Object1::func7(Data1*, Data1*)':
test12.cpp:50:13: warning: Using variable 'ptr2' without checking for null pointer
         int tmp = ptr1 ? ptr1->val : (!ptr2 ? ptr2->val : 0);
             ^
test12.cpp:50:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:50:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:50:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:50:13: warning: Using variable 'ptr2' without checking for null pointer
test12.cpp:50:13: warning: Using variable 'ptr2' without checking for null pointer