예제 #1
0
        public void IsClsCompliant()
        {
            if (AttributeTester.IsClsCompliant(parameter_type))
            {
                return;
            }

            RootContext.ToplevelTypes.Compiler.Report.Warning(3001, 1, Location, "Argument type `{0}' is not CLS-compliant", GetSignatureForError());
        }
예제 #2
0
        //TODO: duplicate
        protected override bool VerifyClsCompliance()
        {
            if (!base.VerifyClsCompliance())
            {
                return(false);
            }

            Parameters.VerifyClsCompliance();

            if (!AttributeTester.IsClsCompliant(ReturnType.Type))
            {
                Report.Warning(3002, 1, Location, "Return type of `{0}' is not CLS-compliant",
                               GetSignatureForError());
            }
            return(true);
        }