On Saturday, 5 October 2019 at 06:40:35 UTC, Arun Chandrasekaran wrote:
On Saturday, 5 October 2019 at 02:59:58 UTC, Paul Backus wrote:
I was curious how C++17's std::variant compared to the options we have in D, like Algebraic and SumType, so I did a simple comparison of the generated assembly for each of them. You can read about it at the link below. And as you can probably guess from the title, D comes out ahead, in the end.

https://pbackus.github.io/blog/beating-stdvisit-without-really-trying.html

This is my first attempt at sharing something like this, so any comment or feedback is very much appreciated!

Good one. Any plans to push SumType as a replacement of Phobo's Algebraic?

Phobos is essentially dead/frozen (feature-wise). Though if someone ever manages to get v2 of the ground, SumType would be the obvious choice.

Anyhow, currently we would have to name it differently (e.g. dts - https://github.com/wilzbach/dts). Maybe the upcoming SAoC project will change this and allow multiple versions of a library to co-exist in a binary.

  • Blog Post: Beating std:... Paul Backus via Digitalmars-d-announce
    • Re: Blog Post: Bea... Meta via Digitalmars-d-announce
    • Re: Blog Post: Bea... Arun Chandrasekaran via Digitalmars-d-announce
      • Re: Blog Post:... Seb via Digitalmars-d-announce
        • Re: Blog P... Paul Backus via Digitalmars-d-announce
        • Re: Blog P... Andrei Alexandrescu via Digitalmars-d-announce
          • Re: Bl... Tobias Pankrath via Digitalmars-d-announce
        • Re: Blog P... Walter Bright via Digitalmars-d-announce
          • Re: Bl... Seb via Digitalmars-d-announce
            • R... Joseph Rushton Wakeling via Digitalmars-d-announce
              • ... Joseph Rushton Wakeling via Digitalmars-d-announce
                • ... Adam D. Ruppe via Digitalmars-d-announce
                • ... Joseph Rushton Wakeling via Digitalmars-d-announce
                • ... Paul Backus via Digitalmars-d-announce

Reply via email to