• zerofk@lemmy.zip
    link
    fedilink
    arrow-up
    2
    ·
    3 hours ago
    #include <cmath>
    #include <iostream>
    #include <numbers>
    
    int main()
    {
      decltype ( NAN ) f { std::numbers::pi };
      std::cout << f << std::endl;
    } 
    
    • marcos@lemmy.world
      link
      fedilink
      arrow-up
      1
      ·
      3 hours ago

      Dude, after forcing -std=c++20, the compiler still can’t find a reference for std::ostream::operator<<(float)

      Do I have to link with some non-standard library? There doesn’t seem to have any numbers.a included with gcc.