[Mono-list] Debug.Assert - a cross-platform issue
MarLOne
InfoSeeker002 at gmail.com
Fri Mar 7 14:17:47 UTC 2014
Hi,
Why is Debug.Assert(false) not terminating/aborting not a bug and has not
been fixed since it was first raised in 2006?
I am using MD4.2.2 in Mint-15 and it still fails to behave correctly out of
the box and wasting people's effort. Sure, one can register tracelistener
into the chain. But if the declaration in mono-projects' web page is serious
about "Run your applications on all platforms", then Mono has to address all
these cross-platform runtime issues and not just being able to compile C#
constructs (I have two reported - XmlSerializer and
TimeZoneInfo.GetSystemTimeZones). You need to make sure the runtime
behaviour is the same as in Windows and other Platform when mono support
those constructs.
Debug.Assert() is a widely use construct that dated back to .Net 1 to catch
violation in debug mode.
I have been programming in CLR since if was in beta and it is so
disheartening that one cannot take code from Windows/CLR over to Mono with
great confidence. It is like playing MineSweeper as you never know when you
step on a mine!
Anyone contemplating of using Mono as a cross platform tool needs to
consider mono as a high risk exercise. Don't just trust it because it can
compile your C# constructs as it only produces compiler-happy code.
Please fix up the Debug.Assert() as it is definitely a bug. If those that
have all these tricks to make it working, why can't they add them as the
default behaviour so that if Debug.Assert(false) terminates in CLR, it
should do that in Mono out of the box and even running inside MonoDevelop is
an improvement.
MarL.
--
View this message in context: http://mono.1490590.n4.nabble.com/Debug-Assert-a-cross-platform-issue-tp4662174.html
Sent from the Mono - General mailing list archive at Nabble.com.
More information about the Mono-list
mailing list