
18 Aug
2005
18 Aug
'05
1:05 p.m.
From: John Torjo <john.lists@torjo.com>
You're right. What comes to mind, is to have an extra parameter: bool add_even_if_name_exists.
So, if passing 'false', if "display" already exists, it's not added. If passing 'true', "display" is added even if it exists.
I suggest using an enumerated type. When called from user code, "true" and "false" convey no information. Enumerators can make the call self-documenting. -- Rob Stewart stewart@sig.com Software Engineer http://www.sig.com Susquehanna International Group, LLP using std::disclaimer;