[llvm-bugs] [Bug 40772] New: Access metadata via Go binding API.
via llvm-bugs
llvm-bugs at lists.llvm.org
Tue Feb 19 05:13:12 PST 2019
https://bugs.llvm.org/show_bug.cgi?id=40772
Bug ID: 40772
Summary: Access metadata via Go binding API.
Product: libraries
Version: trunk
Hardware: Macintosh
OS: MacOS X
Status: NEW
Severity: enhancement
Priority: P
Component: Core LLVM classes
Assignee: unassignedbugs at nondot.org
Reporter: mail at wud.me
CC: llvm-bugs at lists.llvm.org
I am writing a compiler using Go, and need to save some Type Information of
current source code, which can be used while compiling other source files. Go
binding have some method e.g.
func (m Module) AddNamedMetadataOperand(name string, operand Metadata)
func (v Value) SetMetadata(kind int, node Metadata)
to write Metadata, but no function to read it.
func (v Value) Metadata(kind int) (rv Value)
just returns an llvm.Value that I cannot access it as String, only I can do is
call Dump() method and redirect the output to a buffer, and parse it by myself.
Could you offer some method like
func (m Module) GetNamedMetadataOperand(name string)
or
func (v Value) GetMDString(kind int)?
that can access Metadata easier?
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20190219/e708967b/attachment-0001.html>
More information about the llvm-bugs
mailing list