This is an archive of the discontinued LLVM Phabricator instance.

[lldb] Move ScriptInterpreter Interfaces to subdirectory (NFC)
ClosedPublic

Authored by mib on Aug 25 2023, 3:19 AM.

Details

Summary

As we're consolidating and streamlining the various scripting
affordances of lldb, we keep creating new interface files.

This patch groups all the current interface files into a separate sub
directory called Interfaces both in the core Interpreter directory
and the ScriptInterpreter plugin directory.

Signed-off-by: Med Ismail Bennani <ismail@bennani.ma>

Diff Detail

Event Timeline

mib created this revision.Aug 25 2023, 3:19 AM
Herald added a project: Restricted Project. · View Herald TranscriptAug 25 2023, 3:19 AM
mib requested review of this revision.Aug 25 2023, 3:19 AM

Re-organizing the paths seems okay to me, especially since this is going to grow further. I think the header guards are going to need some adjustment though.

lldb/include/lldb/Interpreter/Interfaces/ScriptedProcessInterface.h
9–10

I think the LLVM convention is to reserve underscores for the / in the file path.

mib added a comment.Aug 29 2023, 11:44 AM

Re-organizing the paths seems okay to me, especially since this is going to grow further. I think the header guards are going to need some adjustment though.

TBH, I didn't even know they were guidelines wrt header guards 😅

For long file names, I've been using this pattern in the past of separating the words by _ in the header guards, which also makes it more readable.

I don't think that causes any harm but if you feel strongly about it I can change it.

Re-organizing the paths seems okay to me, especially since this is going to grow further. I think the header guards are going to need some adjustment though.

TBH, I didn't even know they were guidelines wrt header guards 😅

For long file names, I've been using this pattern in the past of separating the words by _ in the header guards, which also makes it more readable.

I don't think that causes any harm but if you feel strongly about it I can change it.

I don't think it's a huge deal personally. If you look hard enough, LLDB (and probably LLVM) are full of tiny mistakes in the header guard from moving files around.

For reference, the LLVM coding standards talks about it here: https://llvm.org/docs/CodingStandards.html#header-guard

mib updated this revision to Diff 554991.Aug 31 2023, 5:14 AM
mib marked an inline comment as done.

Address @bulbazord comments.

bulbazord accepted this revision.Aug 31 2023, 10:00 AM

LGTM thank you!

This revision is now accepted and ready to land.Aug 31 2023, 10:00 AM
This revision was landed with ongoing or failed builds.Oct 23 2023, 9:52 AM
This revision was automatically updated to reflect the committed changes.