Gabor Greif | 1558038 | 2010-03-16 09:55:46 +0000 | [diff] [blame] | 1 | //===- llvm/unittest/VMCore/InstructionsTest.cpp - Instructions unit tests ===// |
| 2 | // |
| 3 | // The LLVM Compiler Infrastructure |
| 4 | // |
| 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
| 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
| 9 | |
| 10 | #include "llvm/Instructions.h" |
| 11 | #include "llvm/LLVMContext.h" |
| 12 | #include "gtest/gtest.h" |
| 13 | |
| 14 | namespace llvm { |
| 15 | namespace { |
| 16 | |
Gabor Greif | 35a9b8b | 2010-03-16 10:59:48 +0000 | [diff] [blame^] | 17 | TEST(InstructionsTest, ReturnInst) { |
Gabor Greif | 1558038 | 2010-03-16 09:55:46 +0000 | [diff] [blame] | 18 | LLVMContext &C(getGlobalContext()); |
| 19 | |
Gabor Greif | 35a9b8b | 2010-03-16 10:59:48 +0000 | [diff] [blame^] | 20 | // test for PR6589 |
Gabor Greif | 1558038 | 2010-03-16 09:55:46 +0000 | [diff] [blame] | 21 | const ReturnInst* r0 = ReturnInst::Create(C); |
Gabor Greif | 35a9b8b | 2010-03-16 10:59:48 +0000 | [diff] [blame^] | 22 | EXPECT_EQ(r0->op_begin(), r0->op_end()); |
Gabor Greif | 1558038 | 2010-03-16 09:55:46 +0000 | [diff] [blame] | 23 | } |
| 24 | |
| 25 | } // end anonymous namespace |
| 26 | } // end namespace llvm |