From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ming Zhao Subject: "virtual" C++ keyword used in rte_devargs.h and causes compilation error in C++ Date: Fri, 06 Feb 2015 23:24:15 -0800 Message-ID: <54D5BD9F.7000902@luminatewireless.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit To: dev-VfR2kkLFssw@public.gmane.org Return-path: List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" The code is in rte_devargs.h: rte_devargs.h: /** Used if type is RTE_DEVTYPE_VIRTUAL. */ struct { /** Driver name. */ char drv_name[32]; } virtual; }; Which caused clang compiler to report error when this file is included by a cpp file, the error message is: In file included from net/dpdk/testing/base-test.cc:3: In file included from net/dpdk/testing/base-test.h:8: third-party/dpdk/lib/librte_eal/common/include/rte_devargs.h:89:5: error: 'virtual' can only appear on non-static member functions } virtual; ^ I think we should try to pick another name for this field. I would suggest calling it "vdev" instead, or I'll be happy to take another name if someone comes with a different idea. Thanks! Ming