aboutsummaryrefslogtreecommitdiffstats
path: root/lib/compiler/doc
diff options
context:
space:
mode:
authorJohn Högberg <[email protected]>2018-10-05 10:06:35 +0200
committerJohn Högberg <[email protected]>2018-10-05 11:47:57 +0200
commit3a34f37fbc5af8eca7a70f5dab61dca7ee1706b0 (patch)
treee3cd748cd4a63039165d8479d9328639d75e91cf /lib/compiler/doc
parent16b93b98516df3fcc79a52847fa89fdda5b187c0 (diff)
downloadotp-3a34f37fbc5af8eca7a70f5dab61dca7ee1706b0.tar.gz
otp-3a34f37fbc5af8eca7a70f5dab61dca7ee1706b0.tar.bz2
otp-3a34f37fbc5af8eca7a70f5dab61dca7ee1706b0.zip
compiler: Forward +source flag to epp and fix bug in +deterministic
The source file path as given to `erlc` was included in an implicit file attribute inserted by epp, even when the +source flag was set to something else which was a bit surprising. It was also included when +deterministic was specified, breaking the flag's promise. This commit forwards the +source flag to epp so it inserts the right information, and if +deterministic is given it will be shaved to just the base name of the file, guaranteeing the same result regardless of how the input is reached.
Diffstat (limited to 'lib/compiler/doc')
-rw-r--r--lib/compiler/doc/src/compile.xml7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/compiler/doc/src/compile.xml b/lib/compiler/doc/src/compile.xml
index 1a71c83521..cfbd4c7fda 100644
--- a/lib/compiler/doc/src/compile.xml
+++ b/lib/compiler/doc/src/compile.xml
@@ -203,7 +203,8 @@
<tag><c>deterministic</c></tag>
<item>
<p>Omit the <c>options</c> and <c>source</c> tuples in
- the list returned by <c>Module:module_info(compile)</c>.
+ the list returned by <c>Module:module_info(compile)</c>, and
+ reduce the paths in stack traces to the module name alone.
This option will make it easier to achieve reproducible builds.
</p>
</item>
@@ -347,8 +348,8 @@ module.beam: module.erl \
<tag><c>{source,FileName}</c></tag>
<item>
- <p>Sets the value of the source, as returned by
- <c>module_info(compile)</c>.</p>
+ <p>Overrides the source file name as presented in
+ <c>module_info(compile)</c> and stack traces.</p>
</item>
<tag><c>{outdir,Dir}</c></tag>