↧
Answer by Adrian Mole for Clang: no warning with -Wdangling-gsl and curly...
This is a bug in clang's diagnosis. The use of curly braces in your last two cases does not 'fix' the dangling pointer issue.By way of 'confirmation', the Code Analysis tool (static analyser) in Visual...
View ArticleClang: no warning with -Wdangling-gsl and curly braces initialization, bug in...
Consider the following snippet:#include <string>#include <string_view>int main() { auto str = std::string{}; auto sv1 = std::string_view(str +"!"); // <- warning :) std::string_view...
View Article
More Pages to Explore .....