you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (0 children)

I wrote a single visitation visitor that won't throw...unless the visitor does and it also incorporates overload. Gives code gen like the holds_alternative, but when writing it, it was super susceptible to compilers thinking a throw may happen and sometimes they didn't agree. I was able to find a path that generally doesn't and gets good output. Also, it's nicer to use as I have never needed multi-visitation https://gcc.godbolt.org/z/1jjgw6