Skip to content

Xcode 10.1 warning: Possible misuse of comma operator here #15

@funnel20

Description

@funnel20

Thank you for this great class.

While using it in my Xcode 10.1 project, it shows the following warning:

Obfuscator.m:173:25: Possible misuse of comma operator here

This is the code:

// If at end of key data, reset count and
// set key pointer back to start of key value
if (++keyIndex == [self.salt length])
    keyIndex = 0, keyPtr = keyData;

I've solved it by splitting the statements over multiple lines within the IF condition:

// If at end of key data, reset count and
// set key pointer back to start of key value
if (++keyIndex == [self.salt length])
{
    keyIndex = 0;
    keyPtr = keyData;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions