“数组作为属性参数是不符合CLS”的警告,但没有给出任何类型的信息 [英] 'Arrays as attribute arguments is not CLS-compliant' warning, but no type information given

查看:126
本文介绍了“数组作为属性参数是不符合CLS”的警告,但没有给出任何类型的信息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在编译我的解决方案,我得到以下几个警告:

When compiling my solution, I get several warnings of the following:

warning CS3016: Arrays as attribute arguments is not CLS-compliant

这是什么类型的不符合被赋予任何其他信息。在我的项目,我有一些属性需要参数数组论点,它们的构造,但它们都是内部的,而且不应该影响CLS遵守。为什么报错此警告,什么类型就报错了?

No other information on what type is not compliant is given. In my projects I have some attributes that take params array arguments in their constructors, but they are all internal, and that shouldn't affect CLS-compliance. Why is this warning being given, and what type is it being given on?

推荐答案

CS3016

如果你有一个属性,它接受一个数组作为参数,该项目被标记为 CLSCompliant < /一>,你会得到这样的警告。

If you have an attribute which takes an array as argument and the project is marked as CLSCompliant you will get this warning.

这篇关于“数组作为属性参数是不符合CLS”的警告,但没有给出任何类型的信息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆