[valadoc] libvaladoc: Avoid reparsing of comments
- From: Florian Brosch <flobrosch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [valadoc] libvaladoc: Avoid reparsing of comments
- Date: Mon, 6 Aug 2012 21:20:24 +0000 (UTC)
commit eef0cec3e990ea2646ba3cffab1980f65b031a3f
Author: Florian Brosch <flo brosch gmail com>
Date: Sat Jul 21 18:51:03 2012 +0200
libvaladoc: Avoid reparsing of comments
src/libvaladoc/api/enumvalue.vala | 4 ++++
src/libvaladoc/api/errorcode.vala | 4 ++++
src/libvaladoc/api/member.vala | 4 ++++
src/libvaladoc/api/namespace.vala | 4 ++++
src/libvaladoc/api/typesymbol.vala | 4 ++++
src/libvaladoc/taglets/tagletlink.vala | 3 +--
6 files changed, 21 insertions(+), 2 deletions(-)
---
diff --git a/src/libvaladoc/api/enumvalue.vala b/src/libvaladoc/api/enumvalue.vala
index d63af21..b715595 100644
--- a/src/libvaladoc/api/enumvalue.vala
+++ b/src/libvaladoc/api/enumvalue.vala
@@ -56,6 +56,10 @@ public class Valadoc.Api.EnumValue: Symbol {
* { inheritDoc}
*/
internal override void process_comments (Settings settings, DocumentationParser parser) {
+ if (documentation != null) {
+ return ;
+ }
+
if (source_comment != null) {
documentation = parser.parse (this, source_comment);
}
diff --git a/src/libvaladoc/api/errorcode.vala b/src/libvaladoc/api/errorcode.vala
index 8253c1b..c422023 100644
--- a/src/libvaladoc/api/errorcode.vala
+++ b/src/libvaladoc/api/errorcode.vala
@@ -44,6 +44,10 @@ public class Valadoc.Api.ErrorCode : Symbol {
* { inheritDoc}
*/
internal override void process_comments (Settings settings, DocumentationParser parser) {
+ if (documentation != null) {
+ return ;
+ }
+
if (source_comment != null) {
documentation = parser.parse (this, source_comment);
}
diff --git a/src/libvaladoc/api/member.vala b/src/libvaladoc/api/member.vala
index 77df1b7..59a8049 100644
--- a/src/libvaladoc/api/member.vala
+++ b/src/libvaladoc/api/member.vala
@@ -33,6 +33,10 @@ public abstract class Valadoc.Api.Member : Symbol {
}
internal override void process_comments (Settings settings, DocumentationParser parser) {
+ if (documentation != null) {
+ return ;
+ }
+
if (source_comment != null) {
documentation = parser.parse (this, source_comment);
}
diff --git a/src/libvaladoc/api/namespace.vala b/src/libvaladoc/api/namespace.vala
index 0b9b346..85da991 100644
--- a/src/libvaladoc/api/namespace.vala
+++ b/src/libvaladoc/api/namespace.vala
@@ -40,6 +40,10 @@ public class Valadoc.Api.Namespace : Symbol {
* { inheritDoc}
*/
internal override void process_comments (Settings settings, DocumentationParser parser) {
+ if (documentation != null) {
+ return ;
+ }
+
if (source_comment != null) {
documentation = parser.parse (this, source_comment);
}
diff --git a/src/libvaladoc/api/typesymbol.vala b/src/libvaladoc/api/typesymbol.vala
index f829cb1..83b9776 100644
--- a/src/libvaladoc/api/typesymbol.vala
+++ b/src/libvaladoc/api/typesymbol.vala
@@ -49,6 +49,10 @@ public abstract class Valadoc.Api.TypeSymbol : Symbol {
* { inheritDoc}
*/
internal override void process_comments (Settings settings, DocumentationParser parser) {
+ if (documentation != null) {
+ return ;
+ }
+
if (source_comment != null) {
documentation = parser.parse (this, source_comment);
}
diff --git a/src/libvaladoc/taglets/tagletlink.vala b/src/libvaladoc/taglets/tagletlink.vala
index 65a6fc7..49699a5 100644
--- a/src/libvaladoc/taglets/tagletlink.vala
+++ b/src/libvaladoc/taglets/tagletlink.vala
@@ -72,8 +72,7 @@ public class Valadoc.Taglets.Link : InlineTaglet {
}
if (_symbol == null && symbol_name != "main") {
- // TODO use ContentElement's source reference
- string node_segment = (container == null)? "" : container.get_full_name () + ": ";
+ string node_segment = (container is Api.Package)? "" : container.get_full_name () + ": ";
reporter.simple_warning ("%s: %s link: warning: %s does not exist", file_path, node_segment, symbol_name);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]