码迷,mamicode.com
首页 > 其他好文 > 详细

g++ error: extra qualification on member [-fpermissive]

时间:2014-10-21 11:57:03      阅读:145      评论:0      收藏:0      [点我收藏+]

标签:style   blog   http   color   io   os   ar   sp   文件   

以下这段代码是在头文件里面的,DmaOpen DmaClose函数也是直接在class pcie_chip{}里面的。加了个额外的pcie_chip::才会报错。

 

//delete pcie_chip:: this scope identifier to solve g++ error:http://stackoverflow.com/questions/5642367/extra-qualification-error-in-c
        //this usage does not accord to C++ standard , and fuck the MSVC surpport this feature
         
    void /*pcie_chip::*/DmaOpen(  bool fPolling ,  
                            unsigned long  dwOptions ,
                            unsigned char *pdata  ,
                            int64 size ) ;
 
    void  /*pcie_chip::*/DmaClose(  ) ;

 

 

就是上述那样,需要把pcie_chip::注释掉。   MSVC支持的C++太特么不标准了,所以很多程序员养成了恶习。

 

reference:

http://stackoverflow.com/questions/5642367/extra-qualification-error-in-c

g++ error: extra qualification on member [-fpermissive]

标签:style   blog   http   color   io   os   ar   sp   文件   

原文地址:http://www.cnblogs.com/foohack/p/4039855.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!