On Wednesday, 6 December 2017 at 16:07:41 UTC, A Guy With a Question wrote:
Does dmd not compile all source code?

It doesn't. I like to build with a few different options to explicitly test (e.g. build for Windows and Linux and -m32 and -m64 to ensure those all exercised) and for templates, do a -unittest that actually runs it - e.g. instantiate Array!int - to make sure that works and compile with -unittest every so often too. Might also do a `__traits(compiles` or static assert on it too.

Others have explained why this is, but this is a simple way to ensure it compiles at least in some cases to catch typos like this.

Another worry btw: the opDispatch feature will just say `no such property` if it fails to compile its innards. A test might also want to call it explicitly to force error messages.
          • Re: Does dm... A Guy With a Question via Digitalmars-d-learn
            • Re: Do... A Guy With a Question via Digitalmars-d-learn
              • Re... Nick Treleaven via Digitalmars-d-learn
              • Re... Steven Schveighoffer via Digitalmars-d-learn
              • Re... Steven Schveighoffer via Digitalmars-d-learn
              • Re... A Guy With a Question via Digitalmars-d-learn
              • Re... A Guy With a Question via Digitalmars-d-learn
              • Re... Atila Neves via Digitalmars-d-learn
              • Re... Steven Schveighoffer via Digitalmars-d-learn
          • Re: Does dm... Gary Willoughby via Digitalmars-d-learn
  • Re: Does dmd not always comp... Adam D. Ruppe via Digitalmars-d-learn

Reply via email to