Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SR-8971] Expose the REPL/SwiftREPL LLDB classes through the SB Python API #4359

Open
pvieito opened this issue Oct 11, 2018 · 2 comments
Open

Comments

@pvieito
Copy link

pvieito commented Oct 11, 2018

Previous ID SR-8971
Radar rdar://problem/45217698
Original Reporter @pvieito
Type New Feature
Additional Detail from JIRA
Votes 0
Component/s LLDB for Swift
Labels New Feature
Assignee None
Priority Medium

md5: 26b1e6db75851f3854e3d3732eb2a0f8

Issue Description:

As commented in the Swift Forums (https://forums.swift.org/t/jupyter-kernel-launch-the-debugger-with-the-current-triple-in-repl-mode)) this API would be very useful for implementing LLDB-based REPLs from a Python environment (like a Jupyter kernel).

@AnnaZaks
Copy link
Mannequin

AnnaZaks mannequin commented Oct 12, 2018

@swift-ci create

@marcrasi
Copy link
Mannequin

marcrasi mannequin commented Feb 1, 2019

I have started looking closer at this, and I now think that the REPL / SwiftREPL is not the right abstraction to expose through the SBAPI. The REPL / SwiftREPL handles a bunch of commandline UI stuff that is not relevant for a consumer like Jupyter that implements its own UI.

For example, `SwiftREPL::CompleteCode` returns completions in a way that is very specific to how the commandline works (when there is 1 completion, it returns an insertable string so that the UI can insert the text; when there are >1 completions, it returns more detailed "displayable" completions that can't be inserted directly into code because they have type information). The ideal completion API for a consumer like Jupyter would always return some structured data with both "insertable" and "displayable" completions, so that the Jupyter UI can decide what to do with them.

I'm going to try adding a completion function to the SBAPI that is independent from the SwiftREPL completer. This SBAPI completer will return structured completion data.

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
@shahmishal shahmishal transferred this issue from apple/swift May 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant