how to add a new feature to existing c++ code?
I have a question about adding new feature to existing c++ code.
Now my application is using a protocol version, we say p1, basically I pass p1 as parm to the functions or assign p1 to the variable inside the function, I need to add a new protocol verison p2, and based on the type of protocal version, the function should use the corresponsing protocal version, how to implement it?
how to add a new feature to existing c++ code?
===

I have a question about adding new feature to existing c++ code.
Now my application is using a protocol version, we say p1, basically I pass p1 as parm to the functions or assign p1 to the variable inside the function, I need to add a new protocol verison p2, and based on the type of protocal version, the function should use the corresponsing protocal version, how to implement it?