[英]Can one use InternalVisibleTo without strong-named assembly in C#?
I could not find any clear statement on MSDN regarding this, there are some examples with strong names other are without, for me it seems like it should work even without but its not working. 我在MSDN上找不到关于此的任何明确声明,有一些强名称的例子,其他没有,对我而言似乎它应该工作,即使没有但它不起作用。
Thank you 谢谢
The documentation is quite explicit: 文档很明确:
Both the current assembly and the friend assembly must be unsigned, or both must be signed with a strong name.
当前程序集和友元程序集都必须是未签名的,或者两者都必须使用强名称进行签名。 If they are signed with a strong name, the argument to the
InternalsVisibleToAttribute
constructor must include the full public key as well as the name of the assembly.如果使用强名称签名,则
InternalsVisibleToAttribute
构造函数的参数必须包含完整的公钥以及程序集的名称。
See this answer for an example of what full public key means. 有关完整公钥的含义,请参阅此答案 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.