Skip to content

Commit cb0f3a7

Browse files
committed
force .a file creation thru anonymous global variable
1 parent aa32e7a commit cb0f3a7

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/units/dummy.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,11 @@
22
// otherwise units does not compile reliably on all platforms
33
// and the pros conductor will not let you create a template if there is
44
// no .a file
5+
6+
// a global, volatile variable in an anonymous namespace
7+
// its put in an anonymous namespace to guarantee that there won't be any
8+
// linker errors
9+
// 10/10 codebase (i don't feel like PRing a fix to PROS, make is scary)
10+
namespace {
11+
volatile char dummy_var;
12+
}

0 commit comments

Comments
 (0)