File tree Expand file tree Collapse file tree 2 files changed +20
-0
lines changed Expand file tree Collapse file tree 2 files changed +20
-0
lines changed Original file line number Diff line number Diff line change @@ -695,6 +695,8 @@ Bug Fixes to Compiler Builtins
695695
696696- Fix ``__has_builtin `` incorrectly returning ``false `` for some C++ type traits. (#GH111477)
697697
698+ - Fix ``__builtin_source_location `` incorrectly returning wrong column for method chains. (#GH119129)
699+
698700Bug Fixes to Attribute Support
699701^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
700702
Original file line number Diff line number Diff line change @@ -1012,3 +1012,21 @@ int h = Var<int>;
10121012
10131013
10141014}
1015+
1016+ namespace GH119129 {
1017+ struct X {
1018+ constexpr int foo (std::source_location loc = std::source_location::current()) {
1019+ return loc.line ();
1020+ }
1021+ };
1022+ static_assert (X{}.foo() == __LINE__);
1023+ static_assert (X{}.
1024+ foo () ==__LINE__);
1025+ static_assert (X{}.
1026+
1027+
1028+ foo () ==__LINE__);
1029+ #line 10000
1030+ static_assert (X{}.
1031+ foo () == 10001);
1032+ }
You can’t perform that action at this time.
0 commit comments