Commit 22db799a authored by honggyu.kp's avatar honggyu.kp Committed by Commit bot

arm: Fix to pass typed pointer with a cast to %p

This patch fixes the below compilation error with a static_cast.

../src/arm/disasm-arm.cc:689:72:
    error: format specifies type 'void *' but the argument has type
    'v8::internal::byte *' (aka 'unsigned char *') [-Werror,-Wformat-pedantic]
    out_buffer_pos_ += SNPrintF(out_buffer_ + out_buffer_pos_, "%p", addr);

R=yangguo@chromium.org

Review-Url: https://codereview.chromium.org/2900663002
Cr-Commit-Position: refs/heads/master@{#45457}
parent 146cc7db
......@@ -686,7 +686,8 @@ int Decoder::FormatOption(Instruction* instr, const char* format) {
return -1;
}
}
out_buffer_pos_ += SNPrintF(out_buffer_ + out_buffer_pos_, "%p", addr);
out_buffer_pos_ += SNPrintF(out_buffer_ + out_buffer_pos_, "%p",
static_cast<void*>(addr));
return 1;
}
case 'S':
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment