llvm.org GIT mirror llvm / a1e3660
[python-bindings] Added test for reading a module from bitcode. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@190467 91177308-0d34-0410-b5e6-96231b3b80d8 Michael Gottesman 6 years ago
1 changed file(s) with 15 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
0 from .base import TestBase
1 from ..core import OpCode
2 from ..core import MemoryBuffer
3 from ..core import PassRegistry
4 from ..core import Context
5 from ..core import Module
6 from ..bit_reader import parse_bitcode
7
8 class TestBitReader(TestBase):
9
10 def test_parse_bitcode(self):
11 source = self.get_test_bc()
12 m = parse_bitcode(MemoryBuffer(filename=source))
13 print m.target
14 print m.datalayout