function construct_coder_error(ids,msg,throwFlag)
% CONSTRUCT_CODER_ERROR(IDS,MSG,THROWFLAG)

%   Copyright 1995-2013 The MathWorks, Inc.

	if(nargin<3)
		throwFlag = 1;
	end

	sfprivate('coder_error_count_man','add');
	if(isempty(msg))
		msg = getString(message('Stateflow:sfprivate:UnexpectedInternal'));
		throwFlag = 1;
	end

	sfprivate('construct_error',ids,'Coder',msg,throwFlag);
