<div dir="ltr">Yay! that worked. Thanks.<div>Is it possible to add a section to that docs page about using an IDE debugger?</div><div>It was not obvious that one should use ...\OpenJDK\jdk\build\windows-x86_64-server-release\images\jdk instead of ...\OpenJDK\jdk\build\windows-x86_64-server-release\jdk</div><div>to connect the jdk source files to the debugger.</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Jul 12, 2024 at 8:15 PM Chen Liang <<a href="mailto:liangchenblue@gmail.com">liangchenblue@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Hi Anil,<div>If you want to use your local JDK, first build with "make images" and then add the JDK in this directory:</div><div><JDK git repo>/build/<config name>/images/jdk</div><div>"config name" should be chosen by you or configure, looks like "windows-x86-64-server-release"</div><div>Note there's an exploded jdk at /jdk instead of /images/jdk; the one not in images is exploded and does not have sources.</div><div><br></div><div>Regards</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Jul 12, 2024 at 7:55 PM Anil <<a href="mailto:1dropaflame@gmail.com" target="_blank">1dropaflame@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">I am trying to learn the Streams package of the JDK, and successfully built the jdk.<div><div>I set the IDE (IntelliJ Community Edition) to use the JDK.</div><div>I put some dummy output statements in a stream method, peek(), and built the JDK again.<br><div>I was stepping through a toy Java program that uses it, but I see that when it gets to the core/base libraries, it does not use the Java code, but rather, the decompiled code.</div><div>How to get the IDE to use the Java code?</div><div>Here is the code I changed in <span style="font-family:"JetBrains Mono",monospace;font-size:9.8pt;color:rgb(8,8,8)">java.util.stream.</span><span style="font-family:"JetBrains Mono",monospace;font-size:9.8pt;color:rgb(8,8,8)">ReferencePipeline.java</span></div><div><div style="color:rgb(8,8,8)"><pre style="font-family:"JetBrains Mono",monospace;font-size:9.8pt"><span style="color:rgb(0,51,179)">public final </span>Stream<P_OUT> peek(Consumer<? <span style="color:rgb(0,51,179)">super </span>P_OUT> action) {<br>    Objects.requireNonNull(action);<br>    System.out.println(<span style="color:rgb(6,125,23)">"=========anil 3 ================"</span>);<br>    <span style="color:rgb(0,51,179)">return new </span>StatelessOp<>(<span style="color:rgb(0,51,179)">this</span>, StreamShape.REFERENCE,<br>            <span style="color:rgb(23,80,235)">0</span>) {<br>        @Override<br>        Sink<P_OUT> opWrapSink(<span style="color:rgb(0,51,179)">int </span>flags, Sink<P_OUT> sink) {<br>            <span style="color:rgb(0,51,179)">return new </span>Sink.ChainedReference<>(sink) {<br>                @Override<br>                <span style="color:rgb(0,51,179)">public void </span>accept(P_OUT u) {<br>                    System.out.println(<span style="color:rgb(6,125,23)">"=========anil 0 ================"</span>);<br>                    action.accept(u);<br>                    System.out.println(<span style="color:rgb(6,125,23)">"=========anil 1 ================"</span>);<br>                    downstream.accept(u);<br>                    System.out.println(<span style="color:rgb(6,125,23)">"=========anil 2 ================"</span>);<br>                }<br>            };<br>        }<br>    };<br>}<br></pre></div></div><div>thanks,</div><div>Anil</div><div><br></div><div> </div></div></div></div>
</blockquote></div>
</blockquote></div>