Changes in src/SymTab/Validate.cc [084fecc:d24d4e1]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/SymTab/Validate.cc
r084fecc rd24d4e1 823 823 throw SemanticError( "Constructors, destructors, and assignment functions require at least one parameter ", funcDecl ); 824 824 } 825 ReferenceType * refType = dynamic_cast< ReferenceType * >( params.front()->get_type() );826 if ( ! refType) {827 throw SemanticError( "First parameter of a constructor, destructor, or assignment function must be a reference", funcDecl );825 PointerType * ptrType = dynamic_cast< PointerType * >( params.front()->get_type() ); 826 if ( ! ptrType || ptrType->is_array() ) { 827 throw SemanticError( "First parameter of a constructor, destructor, or assignment function must be a pointer ", funcDecl ); 828 828 } 829 829 if ( InitTweak::isCtorDtor( funcDecl->get_name() ) && returnVals.size() != 0 ) {
Note:
See TracChangeset
for help on using the changeset viewer.