[Bitcoin-development] # error "Bitcoin cannot be compiled without assertions." <<<<NOT
mike at plan99.net
Wed Jun 4 09:51:31 UTC 2014
FYI your mail is being spamfoldered due to Yahoo's DMARC policy and the
brokenness of the SF.net mailing list software. I would not expect to get
replies reliably whilst this is the case. I think we should move away from
SF.net for hosting mailing lists personally, because it's this list that's
at fault not Yahoo, but until then you may wish to send to the list with a
different email address.
As to your question,
assert() should have *no* side effects, that is the problem.
> a great book, BTW. Everyone who thinks they know what they are doing when
> they write C++ should read this book! They will realize that they don't
> know Jack [image: Roll Eyes]
> Why weren't these and all the other examples of amateur, i.e.,
> non-professional, software fixed way back in version 0.3.0 in 2010, before
> any more releases were done? And why were these and other sub-standard
> coding practices continued and expanded in later releases, right up until
> the present?
Back in 2010 most code was still being written by Satoshi so perhaps you
should ask him. Regardless, it's very common for professional codebases to
require assertions be enabled. For example the entire Google C++ codebase
uses always-on assertions that have side effects liberally: it's convenient
and safe, when you have the guarantee the code will always run, and the
performance benefits of compiling out assertions are usually non-existent.
So for this reason I think Bitcoin Core currently will fail to build if
assertions are disabled, and that seems OK to me.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the bitcoin-dev