MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / to_symbol

Function to_symbol

tools/WCS.py:31–44  ·  view source on GitHub ↗
(read_elf_line)

Source from the content-addressed store, hash-verified

29 from subprocess import check_output
30
31 def to_symbol(read_elf_line):
32 v = read_elf_line.split()
33
34 s2 = Symbol()
35 s2.value = int(v[1], 16)
36 s2.size = int(v[2])
37 s2.type = v[3]
38 s2.binding = v[4]
39 if len(v) >= 8:
40 s2.name = v[7]
41 else:
42 s2.name = ""
43
44 return s2
45
46 output = check_output([read_elf_path, "-s", "-W", file]).decode(stdout_encoding)
47 lines = output.splitlines()[3:]

Callers 1

read_symbolsFunction · 0.85

Calls 1

SymbolClass · 0.85

Tested by

no test coverage detected