Skip to content

[Coverity] Potential nullptr dereference #3179

Open
@AlexeySachkov

Description

@AlexeySachkov

See details at https://scan.coverity.com/projects/intel-llvm?tab=overview as CID 490176:

Src = ConstantExpr::getPointerCast(dyn_cast<Constant>(Src), IntTy);

If we don't expect the cast to fail, then we should use cast instead of dyn_cast. The former contains an assertion instead of runtime check

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomers

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions