[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-04-30 Thread Dave Lee via lldb-commits
kastiglione wrote: revert: 0f628fdb1aa8be97a5d86c3259b8caaa997790ec apologies, thanks for reporting @aaupov. https://github.com/llvm/llvm-project/pull/81196 ___ lldb-commits mailing list lldb-commits@lists.llvm.org

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-04-30 Thread Amir Ayupov via lldb-commits
aaupov wrote: This diff broke buildbot: https://lab.llvm.org/buildbot/#/builders/68/builds/73367 https://github.com/llvm/llvm-project/pull/81196 ___ lldb-commits mailing list lldb-commits@lists.llvm.org

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-04-30 Thread Dave Lee via lldb-commits
https://github.com/kastiglione closed https://github.com/llvm/llvm-project/pull/81196 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-04-30 Thread Dave Lee via lldb-commits
https://github.com/kastiglione updated https://github.com/llvm/llvm-project/pull/81196 >From 81a2034ff2b41e30a1f5b82c86b4d5d4c429ed52 Mon Sep 17 00:00:00 2001 From: Dave Lee Date: Thu, 8 Feb 2024 13:59:12 -0800 Subject: [PATCH 1/9] [lldb] Support custom printf formatting for variables ---

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-04-30 Thread Dave Lee via lldb-commits
https://github.com/kastiglione updated https://github.com/llvm/llvm-project/pull/81196 >From 81a2034ff2b41e30a1f5b82c86b4d5d4c429ed52 Mon Sep 17 00:00:00 2001 From: Dave Lee Date: Thu, 8 Feb 2024 13:59:12 -0800 Subject: [PATCH 1/8] [lldb] Support custom printf formatting for variables ---

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-04-30 Thread Dave Lee via lldb-commits
https://github.com/kastiglione updated https://github.com/llvm/llvm-project/pull/81196 >From 81a2034ff2b41e30a1f5b82c86b4d5d4c429ed52 Mon Sep 17 00:00:00 2001 From: Dave Lee Date: Thu, 8 Feb 2024 13:59:12 -0800 Subject: [PATCH 1/7] [lldb] Support custom printf formatting for variables ---

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-21 Thread Dave Lee via lldb-commits
@@ -0,0 +1,18 @@ +import lldb +from lldbsuite.test.lldbtest import * +import lldbsuite.test.lldbutil as lldbutil + + +class TestCase(TestBase): + +def test_raw_bytes(self): +self.build() +lldbutil.run_to_source_breakpoint(self, "break here",

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-21 Thread Adrian Prantl via lldb-commits
@@ -659,20 +660,24 @@ static char ConvertValueObjectStyleToChar( } static bool DumpValueWithLLVMFormat(Stream , llvm::StringRef options, -ValueObject ) { +ValueObject ) { std::string formatted;

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-21 Thread Adrian Prantl via lldb-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/81196 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-21 Thread Adrian Prantl via lldb-commits
@@ -0,0 +1,18 @@ +import lldb +from lldbsuite.test.lldbtest import * +import lldbsuite.test.lldbutil as lldbutil + + +class TestCase(TestBase): + +def test_raw_bytes(self): +self.build() +lldbutil.run_to_source_breakpoint(self, "break here",

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-21 Thread Adrian Prantl via lldb-commits
https://github.com/adrian-prantl edited https://github.com/llvm/llvm-project/pull/81196 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-21 Thread via lldb-commits
github-actions[bot] wrote: :warning: Python code formatter, darker found issues in your code. :warning: You can test this locally with the following command: ``bash darker --check --diff -r 0572dabb71147fdc156d90a3ecd036d1652c2006...16b8dfab53008c657c82b0ae35510c7050481bdb

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-21 Thread Dave Lee via lldb-commits
https://github.com/kastiglione updated https://github.com/llvm/llvm-project/pull/81196 >From 81a2034ff2b41e30a1f5b82c86b4d5d4c429ed52 Mon Sep 17 00:00:00 2001 From: Dave Lee Date: Thu, 8 Feb 2024 13:59:12 -0800 Subject: [PATCH 1/6] [lldb] Support custom printf formatting for variables ---

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-20 Thread Dave Lee via lldb-commits
@@ -0,0 +1,11 @@ +import lldb +from lldbsuite.test.lldbtest import * +import lldbsuite.test.lldbutil as lldbutil + + +class TestCase(TestBase): +def test(self): +self.build() +lldbutil.run_to_source_breakpoint(self, "break here", lldb.SBFileSpec("main.c")) +

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-20 Thread Dave Lee via lldb-commits
@@ -658,6 +658,33 @@ static char ConvertValueObjectStyleToChar( return '\0'; } +static bool DumpValueWithLLVMFormat(Stream , llvm::StringRef options, +ValueObject ) { + std::string formatted; + std::string llvm_format = ("{0:" + options

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-20 Thread Greg Clayton via lldb-commits
@@ -658,6 +658,33 @@ static char ConvertValueObjectStyleToChar( return '\0'; } +static bool DumpValueWithLLVMFormat(Stream , llvm::StringRef options, +ValueObject ) { clayborg wrote: Can we named this something other

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-20 Thread Adrian Prantl via lldb-commits
@@ -0,0 +1,11 @@ +import lldb +from lldbsuite.test.lldbtest import * +import lldbsuite.test.lldbutil as lldbutil + + +class TestCase(TestBase): +def test(self): +self.build() +lldbutil.run_to_source_breakpoint(self, "break here", lldb.SBFileSpec("main.c")) +

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-20 Thread Adrian Prantl via lldb-commits
@@ -658,6 +658,33 @@ static char ConvertValueObjectStyleToChar( return '\0'; } +static bool DumpValueWithLLVMFormat(Stream , llvm::StringRef options, +ValueObject ) { + std::string formatted; + std::string llvm_format = ("{0:" + options

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-19 Thread Dave Lee via lldb-commits
kastiglione wrote: @jimingham now that I've switched to llvm format, I'll loop back and follow up on your comments. https://github.com/llvm/llvm-project/pull/81196 ___ lldb-commits mailing list lldb-commits@lists.llvm.org

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-19 Thread Dave Lee via lldb-commits
kastiglione wrote: I've updated this PR to use llvm formatting instead of printf. For the following reasons: 1. For printf, users would have to know the system's size of the value, eg `%d` vs `%ld` etc 2. Users would have to provide different values for different systems, which limits the

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-19 Thread Dave Lee via lldb-commits
https://github.com/kastiglione edited https://github.com/llvm/llvm-project/pull/81196 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

[Lldb-commits] [lldb] [lldb] Support custom LLVM formatting for variables (PR #81196)

2024-03-19 Thread Dave Lee via lldb-commits
https://github.com/kastiglione edited https://github.com/llvm/llvm-project/pull/81196 ___ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits