Welcome, Guest. Please login or register.

Author Topic: Please help me stop insane SASC warning 317  (Read 2474 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline PiR

  • Full Member
  • ***
  • Join Date: Apr 2003
  • Posts: 148
    • Show all replies
Re: Please help me stop insane SASC warning 317
« on: September 13, 2004, 04:42:22 PM »
I've observed that SAS/C is sometimes 'overprotective' in case of uninitialized variables, but at least from my observations, it happened mostly with conditional instructions, like:

Code: [Select]

int i;
int j;

/* blablabla */

if( i == 0 ) {
  j = 0; // initailized really conditionally
}

if( i == 0 ) {
  printf( "%d", j ); // whenever used its always initialized
}


In this case it is hard to judge, just having list of warnings and sample of code to prove its wrong. Sometimes That Important Something is hidden in the place of code we do not expect it at all.
However I don't know really - mayby it is just like so. By the way - which version of SAS/C are you using?

Anyway one VERY IMPORTANT COMMENT FROM ME:
Quote
 FOR (count=0;count<=256; count++) DO

carefull PLEASE(!!!):
count < 256