This is an archive of the discontinued LLVM Phabricator instance.

[LLDB] Add some declarations related to REPL support for mojo
ClosedPublic

Authored by wallace on May 10 2023, 1:42 PM.

Details

Summary

This simple diff declares some enum values needed to create a REPL for the mojo language.

Diff Detail

Event Timeline

wallace created this revision.May 10 2023, 1:42 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 10 2023, 1:42 PM
wallace requested review of this revision.May 10 2023, 1:42 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 10 2023, 1:42 PM

Could we switch the RTTI to use the llvm RTTI extension mechanism, instead of enums? Other classes have started doing this, and it'd be really nice if users can write REPLS without needing to touch upstream LLDB.

Could we switch the RTTI to use the llvm RTTI extension mechanism, instead of enums? Other classes have started doing this, and it'd be really nice if users can write REPLS without needing to touch upstream LLDB.

+1, LLVM's RTTI mechanism would make it easier to add new things without needing to change base classes.

wallace updated this revision to Diff 524398.May 22 2023, 11:05 AM

address comments

bzcheeseman added inline comments.May 22 2023, 11:25 AM
lldb/include/lldb/Expression/ExpressionTypeSystemHelper.h
32

I was expecting you'd just use RTTIExtends from Support/ExtensibleRTTI.h, any reason not to use that?

Sure, I can use it. I just didn't know it exists :)

wallace updated this revision to Diff 524448.May 22 2023, 12:58 PM

Use RTTIExtends

This revision is now accepted and ready to land.May 22 2023, 1:13 PM
bulbazord accepted this revision.May 23 2023, 10:04 AM