[PATCH] D106363: [ADT] Add initializer_list constructor to SmallDenseMap
David Blaikie via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 20 11:51:47 PDT 2021
dblaikie accepted this revision.
dblaikie added a comment.
This revision is now accepted and ready to land.
Sounds good
================
Comment at: llvm/unittests/ADT/DenseMapTest.cpp:551
+TEST(DenseMapCustomTest, SmallDenseMapInitializerList) {
+ SmallDenseMap<int, int> M({{0, 0}, {0, 1}, {1, 2}});
+ EXPECT_EQ(2u, M.size());
----------------
I'd probably test this with `=` rather than `()` style syntax - to demonstrate that it's intentional/verify that implicit construction works
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D106363/new/
https://reviews.llvm.org/D106363
More information about the llvm-commits
mailing list