当我编译应用程序时,我发现以下错误我不知道我更喜欢的屏幕,因为我已经在课堂上创建了这些方法并且复制了可以帮助我的人吗?
Error 2 error C2062: type 'double' unexpected
Error 7 error C2065: 'd' : undeclared identifier
Error 1 error C2065: 'square_list' : undeclared identifier
Error 8 error C2228: left of '.begin' must have class/struct/union
Error 4 error C2228: left of '.empty' must have class/struct/union
Error 9 error C2228: left of '.end' must have class/struct/union
Error 6 error C2228: left of '.size' must have class/struct/union
测试单位
BOOST_AUTO_TEST_CASE( ut_ctor_default ) { square_list<double> d; BOOST_CHECK( d.empty() ); BOOST_CHECK( d.size() == 0 ); BOOST_CHECK( d.begin() == d.end() ); }
我的班级
答案 0 :(得分:0)
您将该类命名为Sqaure_List
,但在您的测试用例中,您使用了名称square_list