diff options
author | Ian Lance Taylor <iant@golang.org> | 2010-03-23 06:46:30 -0700 |
---|---|---|
committer | Ian Lance Taylor <iant@golang.org> | 2010-03-23 06:46:30 -0700 |
commit | 657722838b27230a6affe26c150529ea21de360a (patch) | |
tree | 51bae5f6a4a8102569673b40c33f03d1c402f03f /src/cmd/6c/swt.c | |
parent | 58a5e402e7c7465451a82ae796bfd097681b440b (diff) | |
download | go-657722838b27230a6affe26c150529ea21de360a.tar.gz |
Add support for #pragma dynexport.
R=rsc
CC=golang-dev
http://codereview.appspot.com/661043
Diffstat (limited to 'src/cmd/6c/swt.c')
-rw-r--r-- | src/cmd/6c/swt.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/cmd/6c/swt.c b/src/cmd/6c/swt.c index cdb948f89..0c8370468 100644 --- a/src/cmd/6c/swt.c +++ b/src/cmd/6c/swt.c @@ -232,7 +232,7 @@ outcode(void) Binit(&b, f, OWRITE); Bprint(&b, "%s\n", thestring); - if(ndynimp > 0) { + if(ndynimp > 0 || ndynexp > 0) { int i; Bprint(&b, "\n"); @@ -241,7 +241,10 @@ outcode(void) Bprint(&b, "$$ // dynimport\n", thestring); for(i=0; i<ndynimp; i++) Bprint(&b, "dynimport %s %s %s\n", dynimp[i].local, dynimp[i].remote, dynimp[i].path); - Bprint(&b, "$$\n\n"); + Bprint(&b, "\n$$ // dynexport\n", thestring); + for(i=0; i<ndynexp; i++) + Bprint(&b, "dynexport %s %s\n", dynexp[i].local, dynexp[i].remote); + Bprint(&b, "\n$$\n\n"); } Bprint(&b, "!\n"); |