BUG: 'temp' used in exception message after delete

The variable 'temp' was used in the exception message
after it was deleted.  This patch generates the
message, deletes 'temp', and then throws the exception
with the message.

Change-Id: Ic95b612690667277dfd134a6018316eabce626d0
ENH: Define print of null smart pointers

Print "(null)" instead of segfaulting. While this is different than a
raw pointers behavior, this is much more user friendly.

Change-Id: I3d311f0e6d575d7def44b34e5c0cc42f066d52c3
Merge topic 'PointersPrintNull'

3c63779 ENH: Define print of null smart pointers
Merge topic 'OrderDeleteException'

89bb5d7 BUG: 'temp' used in exception message after delete