[PATCH] [llgo] irgen: return a types.Package to the compiler client

Peter Collingbourne peter at pcc.me.uk
Tue Dec 30 16:26:44 PST 2014


REPOSITORY
  rL LLVM

http://reviews.llvm.org/D6802

Files:
  llgo/trunk/irgen/compiler.go

Index: llgo/trunk/irgen/compiler.go
===================================================================
--- llgo/trunk/irgen/compiler.go
+++ llgo/trunk/irgen/compiler.go
@@ -38,6 +38,7 @@
 	llvm.Module
 	Path       string
 	ExportData []byte
+	Package    *types.Package
 	disposed   bool
 }
 
@@ -194,7 +195,7 @@
 
 	// Create a Module, which contains the LLVM module.
 	modulename := importpath
-	compiler.module = &Module{Module: llvm.NewModule(modulename), Path: modulename}
+	compiler.module = &Module{Module: llvm.NewModule(modulename), Path: modulename, Package: mainPkg.Object}
 	compiler.module.SetTarget(compiler.TargetTriple)
 	compiler.module.SetDataLayout(compiler.dataLayout)

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D6802.17734.patch
Type: text/x-patch
Size: 691 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141231/c6858696/attachment.bin>


More information about the llvm-commits mailing list