Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8284039

Clarify --source-path and // @start tag usage in programmer guide, JEP and spec

XMLWordPrintable

      Programmer's Guide to Snippets created to cover the additions as a part JEP 413 could use a few updates.

      It's not clear in the document that you must define the `--source-path` for snippets located in snippet-files folders to be automatically detected.

      It's also not clear that //@start is inclusive of the line it is defined on. Intuitively many programmers might expect that // @start must be defined on the line before the region that is wished to be captured.

      https://docs.oracle.com/en/java/javase/18/code-snippet/index.html

            jjg Jonathan Gibbons
            bkorando Billy Korando
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: