Opened 8 years ago

Closed 8 years ago

#10978 closed Bugs (fixed)

libs/coroutine/test_asymmetric_coroutine.cpp test violates C++ Standard

Reported by: sergey.sprogis@… Owned by: olli
Milestone: To Be Determined Component: coroutine
Version: Boost 1.57.0 Severity: Problem
Keywords: Cc:

Description

  1. Description of the failure.

On Solaris 11.2 Oracle Studio 12.4 C++ compiler produces the following error message for libs/coroutine/test/test_asymmetric_coroutine.cpp source.

"test_asymmetric_coroutine.cpp", line 66: Error: "}" expected instead of ";".

and actually it produces similar error message for small test like this:

class moveable {

private: ;

}

  1. Cause of the failure.

This test violates C++ Standard ================== Chapter 9, abbreviated syntax productions.

class-specifier:

class-head { member-specfication[opt] }

member-specification:

member-declaration member-specification[opt]

member-declaration:

decl-specifier-seq[opt] member-declarator-list[opt] ;

====================

The syntax for member-declaration appears to allow a lone semi-colon, except for this requirement in Section 9.2p1:

"... member-declarations declare members of the class, and each such member-declaration shall declare

at least one member name of the class."

  1. Possible Solution.
  • Remove the semicolon from line:

BOOST_MOVABLE_BUT_NOT_COPYABLE( moveable);

Change History (2)

comment:1 by Sergey.Sprogis@…, 8 years ago

Component: Regression Testingcoroutine
Owner: changed from René Rivera to olli

comment:2 by olli, 8 years ago

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.