缺少编译器要求会员'System.Runtime.CompilerServices.ExtensionAttribute..ctor“

编程入门 行业动态 更新时间:2024-10-26 04:28:45
本文介绍了缺少编译器要求会员'System.Runtime.CompilerServices.ExtensionAttribute..ctor“的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我有针对性地.NET 4.0的项目。它用来建立,直到昨天。我看着代码和引用的程序。我可以看到所定义的扩展属性。 。任何人有任何关于它的线索

I have a project targeted to .Net 4.0. It used to build till yesterday. I looked at code and referenced assemblies. I can see the Extension attribute defined. Anyone has any clue about it.

我提到以下几个问题,但没有任何帮助 - 的"缺少编译器要求会员"而几乎没有改变代码抛出错误多次

I referred following questions but no help - "Missing compiler required member" error being thrown multiple times with almost no changes to code

*更新1:* 我看到Npgsql在相同的命名空间定义ExtensionAttribute。当我删除,并添加Npgsql的旧版本,它内置。我应该怎么做才能使用最新的Npgsql?

* UPDATE 1: * I see Npgsql is defining ExtensionAttribute in the same namespace. When I removed and added older version of Npgsql, it built. What should I do to use latest Npgsql?

推荐答案

这发生在我最近,我的研究一直回来与JSON.Net不是针对存在的问题正确的版本。

This happened to me recently, and my research kept coming back to problems with JSON.Net not targeting the correct version.

如果您正在使用它,我建议从你引用删除它,和删除您packages.config行也引用它。然后通过的NuGet重新安装和编译。

If you are using it, I would suggest removing it from your references, and removing the lines from your packages.config that also reference it. Then re-install it through NuGet and compile.

更多推荐

缺少编译器要求会员'System.Runtime.CompilerServices.ExtensionAttribute..ctor“

本文发布于:2023-11-12 04:44:37,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1580538.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:编译器   会员   System   ctor   ExtensionAttribute

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!