kadircet marked an inline comment as done. kadircet added inline comments.
================ Comment at: clang-tools-extra/clangd/Hover.cpp:247 + // to the enclosing call. + if (E->getType()->isFunctionType() || E->getType()->isFunctionPointerType() || + E->getType()->isFunctionReferenceType()) ---------------- nit extract `E->getType()` into a variable ================ Comment at: clang-tools-extra/clangd/Hover.cpp:255 + // Show enums symbolically, not numerically like APValue::printPretty(). + if (E->getType()->isEnumeralType() && + Constant.Val.getInt().getMinSignedBits() <= 64) { ---------------- both `Constant.Val.getInt` and `ECD->getInitVal` are `APSInt` and it has an `operator==`, why cast to `int64_t` in between? ================ Comment at: clang-tools-extra/clangd/unittests/HoverTests.cpp:278 }; + HI.Value = "false"; return HI; ---------------- wow, that's hilarious. ================ Comment at: clang-tools-extra/clangd/unittests/HoverTests.cpp:450 + HI.Type = "enum Color"; + HI.Value = "GREEN"; // Symbolic when hovering on an expression. }}, ---------------- what about `GREEN (1)` ? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D70359/new/ https://reviews.llvm.org/D70359 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits