http://llvm.org/bugs/show_bug.cgi?id=21983

            Bug ID: 21983
           Summary: Add Clang warning to suggest merge of variable
                    declaration and initialization
           Product: new-bugs
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: new bugs
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected]
    Classification: Unclassified

Hi!

I think will be good idea to introduce warning which will suggest merge of
variable declaration and initialization for situation like:

int x;

<other variables declarations>

x = 0;

<function code>

Of course dependencies between variables initialization and necessary
reordering could be proposed for cases like:

int x;
struct data_t* Data;

Data = (struct data_t*) ...;
x = Data->x;

Eugene.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to