mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-23 11:13:28 +01:00
[mips] Add an assert in getTargetStreamer()
Check if the TargetStreamer can be accessed. Differential Revision: https://reviews.llvm.org/D71477
This commit is contained in:
parent
e38a8576b2
commit
6ffd0a9d14
@ -134,6 +134,8 @@ namespace {
|
||||
|
||||
class MipsAsmParser : public MCTargetAsmParser {
|
||||
MipsTargetStreamer &getTargetStreamer() {
|
||||
assert(getParser().getStreamer().getTargetStreamer() &&
|
||||
"do not have a target streamer");
|
||||
MCTargetStreamer &TS = *getParser().getStreamer().getTargetStreamer();
|
||||
return static_cast<MipsTargetStreamer &>(TS);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user