<div dir="ltr">I don't know if there's a good way to do that.  Because debuggers need to be able to see across multiple translation units, this is implemented internally as constructing one giant AST that contains everything for the entire program.  LLDB has no notion of a per-module AST, so it would be hard to make this work.<div><br></div></div><br><div class="gmail_quote"><div dir="ltr">On Fri, Dec 14, 2018 at 10:51 AM Pavel Labath <<a href="mailto:pavel@labath.sk">pavel@labath.sk</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On 14/12/2018 19:43, Zachary Turner via lldb-commits wrote:<br>
> Author: zturner<br>
> Date: Fri Dec 14 10:43:42 2018<br>
> New Revision: 349175<br>
> <br>
> URL: <a href="http://llvm.org/viewvc/llvm-project?rev=349175&view=rev" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project?rev=349175&view=rev</a><br>
> Log:<br>
> [NativePDB] Fix local-variables.cpp test.<br>
> <br>
> Since we're actually running an executable on the host now, different<br>
> versions of Windows could load different system libraries, so we need<br>
> to regex out the number of loaded modules.<br>
> <br>
> Modified:<br>
>      lldb/trunk/lit/SymbolFile/NativePDB/local-variables.cpp<br>
> <br>
> Modified: lldb/trunk/lit/SymbolFile/NativePDB/local-variables.cpp<br>
> URL: <a href="http://llvm.org/viewvc/llvm-project/lldb/trunk/lit/SymbolFile/NativePDB/local-variables.cpp?rev=349175&r1=349174&r2=349175&view=diff" rel="noreferrer" target="_blank">http://llvm.org/viewvc/llvm-project/lldb/trunk/lit/SymbolFile/NativePDB/local-variables.cpp?rev=349175&r1=349174&r2=349175&view=diff</a><br>
> ==============================================================================<br>
> --- lldb/trunk/lit/SymbolFile/NativePDB/local-variables.cpp (original)<br>
> +++ lldb/trunk/lit/SymbolFile/NativePDB/local-variables.cpp Fri Dec 14 10:43:42 2018<br>
> @@ -151,7 +151,7 @@ int main(int argc, char **argv) {<br>
>   // CHECK-NEXT: Process {{.*}} exited with status = 18 (0x00000012)<br>
>   <br>
>   // CHECK:      (lldb) target modules dump ast<br>
> -// CHECK-NEXT: Dumping clang ast for 7 modules.<br>
> +// CHECK-NEXT: Dumping clang ast for {{.*}} modules.<br>
>   // CHECK-NEXT: TranslationUnitDecl<br>
>   // CHECK-NEXT: |-FunctionDecl {{.*}} main 'int (int, char **)'<br>
>   // CHECK-NEXT: | |-ParmVarDecl {{.*}} argc 'int'<br>
> <br>
> <br>
> _______________________________________________<br>
> lldb-commits mailing list<br>
> <a href="mailto:lldb-commits@lists.llvm.org" target="_blank">lldb-commits@lists.llvm.org</a><br>
> <a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits</a><br>
> <br>
<br>
It looks like it would be nice to be able to specify the module whose <br>
clang ast one wishes to dump. This would reduce the amount of output, <br>
and with it, the chance of FileCheck picking up some false positives.<br>
</blockquote></div>