سؤال

I was just wondering, would I be able to add and use CodeContracts under System.Diagnostics in Visual Studion 2005?

Thank's

هل كانت مفيدة؟

المحلول

It appears that the answer is no.

https://social.msdn.microsoft.com/forums/en-US/10f23fc4-d9cb-44e2-98a8-36488e7c9f9c/code-contracts-and-vs2005

Given that you can only "prove" an application correct using the more expensive SKU, Code Contracts sort of acts like fancy assertions, which you can simulate withe the Should Library:

https://github.com/erichexter/Should

Or upgrade to a newer version of VS.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top