19

多此一举, C实现 try-catch-自强不息 厚德载物

 5 years ago
source link: http://blog.51cto.com/wangbojing/2120520
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
在做NtyTcp的时候,有一些,就想用c来实现一套try-catch异常处理子系统。不讨论C语言本身为什么不加try-catch,每个开发的朋友对于这个问题,都能说出一大堆的理由。其实我也是不太喜欢强行在c中加入一个try-catch。就像把try-catch的原理跟自己的体会写出来。首先我们来看看,try-catch的使用情景。try {    

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK