summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2013-11-14 10:25:33 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2013-11-14 10:25:33 (GMT)
commit2f86234cbc7748ccb2028dffe113d2acfad28c28 (patch)
tree5a4e684400f8ce16e1a1b639e9133e5f293a6a25 /tools
parent37fbc7330c9e687eac6bc39a0bce202bb4bf83d5 (diff)
parentdffcad90e2d661e520f735c824ddff5f1d630ddd (diff)
downloadtcl-2f86234cbc7748ccb2028dffe113d2acfad28c28.zip
tcl-2f86234cbc7748ccb2028dffe113d2acfad28c28.tar.gz
tcl-2f86234cbc7748ccb2028dffe113d2acfad28c28.tar.bz2
merge trunk
Diffstat (limited to 'tools')
-rw-r--r--tools/genStubs.tcl5
1 files changed, 3 insertions, 2 deletions
diff --git a/tools/genStubs.tcl b/tools/genStubs.tcl
index 93e0a9a..b45e560 100644
--- a/tools/genStubs.tcl
+++ b/tools/genStubs.tcl
@@ -983,6 +983,8 @@ proc genStubs::emitHeader {name} {
append text "#define ${CAPName}_STUBS_REVISION $revision\n"
}
+ append text "\n#ifdef __cplusplus\nextern \"C\" {\n#endif\n"
+
emitDeclarations $name text
if {[info exists hooks($name)]} {
@@ -1010,8 +1012,7 @@ proc genStubs::emitHeader {name} {
append text "} ${capName}Stubs;\n\n"
- append text "#ifdef __cplusplus\nextern \"C\" {\n#endif\n"
- append text "extern const ${capName}Stubs *${name}StubsPtr;\n"
+ append text "extern const ${capName}Stubs *${name}StubsPtr;\n\n"
append text "#ifdef __cplusplus\n}\n#endif\n"
emitMacros $name text