[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-07-12 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev commandeered this revision. v.g.vassilev edited reviewers, added: junaire; removed: v.g.vassilev. v.g.vassilev added a comment. Jun has moved on in his career and I'd like to take responsibility for this patch. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-06-13 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/lib/Headers/__clang_interpreter_runtime_printvalue.h:44 +template >> +inline std::string PrintValueRuntime(const T ) { + return "{not representable}"; Need to use a reserved identifier for everything so you

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-30 Thread Jun Zhang via Phabricator via cfe-commits
junaire added inline comments. Comment at: clang/lib/Interpreter/ValuePrinter.cpp:262 + +static llvm::Expected CompileDecl(Interpreter , + Decl *D) { v.g.vassilev wrote: > Let's add a FIXME here. The

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-30 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 526566. junaire marked 2 inline comments as done. junaire added a comment. Add LLVM preamble Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files:

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-29 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added inline comments. Comment at: clang/lib/Interpreter/ValuePrinter.cpp:1 +#include "InterpreterUtils.h" +#include "clang/AST/ASTContext.h" Please add the llvm preamble. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-29 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added inline comments. Comment at: clang/lib/Interpreter/IncrementalParser.h:86 + Parser () { return *P; } + Is that used? Comment at: clang/lib/Interpreter/ValuePrinter.cpp:262 + +static llvm::Expected CompileDecl(Interpreter

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-29 Thread Jun Zhang via Phabricator via cfe-commits
junaire added inline comments. Comment at: clang/tools/clang-repl/CMakeLists.txt:40 + ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@PEBX@Z + ??6?$basic_ostream@DU?$char_traits@D@std@@@std@@QEAAAEAV01@P6AAEAV01@AEAV01@@Z@Z +

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-29 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 526383. junaire added a comment. Make CreateUniqName a static helper Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files:

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-28 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added inline comments. Comment at: clang/include/clang/Interpreter/Interpreter.h:113 llvm::Expected CompileDtorCall(CXXRecordDecl *CXXRD); + std::string CreateUniqName(std::string Base); We should move this routine to its user in maybe

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-27 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 526256. junaire added a comment. Rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-24 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 525425. junaire added a comment. Remove `Interpereter::getParser` + More clean up Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files:

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-24 Thread Jun Zhang via Phabricator via cfe-commits
junaire added inline comments. Comment at: clang/lib/Interpreter/Interpreter.cpp:434 + +llvm::Expected Interpreter::CompileDecl(Decl *D) { + assert(D && "The Decl being compiled can't be null"); aaron.ballman wrote: > Any way to make this take a `const Decl *`

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-24 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 525420. junaire marked 15 inline comments as done. junaire added a comment. Address comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files:

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-24 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. I didn't have the chance to complete my review (this is a pretty massive change), but here are some in-progress comments. Comment at: clang/include/clang/Interpreter/Interpreter.h:105 + Parser () const; + const mismatch here

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-24 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added subscribers: sunho, sgraenitz, lhames. v.g.vassilev added a comment. I believe this is heading in a good direction. Here are some comments from a partial review. Also perhaps we should extend the patch description (future commit message) to capture the idea of the

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-21 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 524096. junaire added a comment. . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-21 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 524093. junaire added a comment. add `caas` namespace Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-21 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 524091. junaire added a comment. . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-21 Thread Jun Zhang via Phabricator via cfe-commits
junaire added a comment. Invite more people to the party :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 ___ cfe-commits mailing list

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-21 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 524088. junaire added a comment. . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-14 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 521985. junaire added a comment. Make and use our own std::void_t Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files:

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-14 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 521981. junaire added a comment. - include to avoid incorrect lookup on Windows - Add `-Xcc -fno-delayed-template-parsing` to fix failure on Windows Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-13 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 521962. junaire added a comment. Add macro guard. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-13 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 521961. junaire added a comment. Don't use C++17 because Clang on Windows is not default to that :( Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files:

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-10 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 520998. junaire added a comment. Export symbols in Windows. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-10 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 520914. junaire added a comment. Add some comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-10 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 520913. junaire added a comment. Remove unused code. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-10 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 520912. junaire added a comment. Fix Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-01 Thread Jun Zhang via Phabricator via cfe-commits
junaire added inline comments. Comment at: clang/test/Interpreter/pretty-print.cpp:107 +p2 +// CHECK-NEXT: (std::_MakeUniq::__single_object &) std::unique_ptr -> [[Addr:@0x.*]] + junaire wrote: > Hi @mizvekov, do you have a clue about why it doesn't print the

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-05-01 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 518458. junaire added a comment. Fix AutoType sugar Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-04-30 Thread Jun Zhang via Phabricator via cfe-commits
junaire added inline comments. Comment at: clang/test/Interpreter/pretty-print.cpp:107 +p2 +// CHECK-NEXT: (std::_MakeUniq::__single_object &) std::unique_ptr -> [[Addr:@0x.*]] + Hi @mizvekov, do you have a clue about why it doesn't print the correct type? So

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-04-30 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 518289. junaire added a comment. . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-04-30 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 518287. junaire added a comment. . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h

[PATCH] D146809: [clang-repl] Implement Value pretty printing

2023-04-29 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 518266. junaire added a comment. . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146809/new/ https://reviews.llvm.org/D146809 Files: clang/include/clang/Interpreter/Interpreter.h