diff options
author | Donna Malayeri <lindydonna@gmail.com> | 2010-04-26 13:24:12 +0000 |
---|---|---|
committer | Donna Malayeri <lindydonna@gmail.com> | 2010-04-26 13:24:12 +0000 |
commit | 4ab780e8be41a7d47c07e8c6121ebe06ba3dfd89 (patch) | |
tree | 784d1c78d39c9b7719d8c01a1cbc1ce8835744bf | |
parent | 3b24fde83660bf26c1bff4f6ac0240a8c85efa62 (diff) | |
download | scala-4ab780e8be41a7d47c07e8c6121ebe06ba3dfd89.tar.gz scala-4ab780e8be41a7d47c07e8c6121ebe06ba3dfd89.tar.bz2 scala-4ab780e8be41a7d47c07e8c6121ebe06ba3dfd89.zip |
[scaladoc] Added TODO comments for later fixing...
[scaladoc] Added TODO comments for later fixing issue that sourceless
templates are not documented. No review.
-rw-r--r-- | src/compiler/scala/tools/nsc/doc/Settings.scala | 2 | ||||
-rw-r--r-- | src/compiler/scala/tools/nsc/doc/model/ModelFactory.scala | 6 |
2 files changed, 6 insertions, 2 deletions
diff --git a/src/compiler/scala/tools/nsc/doc/Settings.scala b/src/compiler/scala/tools/nsc/doc/Settings.scala index 3d02689605..4897d78488 100644 --- a/src/compiler/scala/tools/nsc/doc/Settings.scala +++ b/src/compiler/scala/tools/nsc/doc/Settings.scala @@ -32,4 +32,6 @@ class Settings(error: String => Unit) extends scala.tools.nsc.Settings(error) { // working around issue described in r18708. suppressVTWarn.value = true + + // TODO: add a new setting for whether or not to document sourceless entities (e.g., Any, Unit, etc) } diff --git a/src/compiler/scala/tools/nsc/doc/model/ModelFactory.scala b/src/compiler/scala/tools/nsc/doc/model/ModelFactory.scala index 3b0cc4df67..e2a25d7ea4 100644 --- a/src/compiler/scala/tools/nsc/doc/model/ModelFactory.scala +++ b/src/compiler/scala/tools/nsc/doc/model/ModelFactory.scala @@ -502,9 +502,11 @@ class ModelFactory(val global: Global, val settings: doc.Settings) { thisFactory val name = optimize(nameBuffer.toString) } - def templateShouldDocument(aSym: Symbol): Boolean = - (aSym.isPackageClass || (aSym.sourceFile != null)) && localShouldDocument(aSym) && + def templateShouldDocument(aSym: Symbol): Boolean = { + // TODO: document sourceless entities (e.g., Any, etc), based on a new Setting to be added + (aSym.isPackageClass || (aSym.sourceFile != null)) && localShouldDocument(aSym) && ( aSym.owner == NoSymbol || templateShouldDocument(aSym.owner) ) + } def localShouldDocument(aSym: Symbol): Boolean = !aSym.isPrivate && (aSym.isProtected || aSym.privateWithin == NoSymbol) && !aSym.isSynthetic |