Issue39: work around g++ warning on the use of boost::optional

I believe this fixes #39 (the second error reported there).  While the code in this branch worked for me, I don't have an environment that uses this particular version of g++, and I cannot prove it with confidence.  If someone can reproduce the original error and confirm the fix (and review it) that would be highly appreciated.