aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDmitri Gribenko <gribozavr@gmail.com>2012-08-06 19:03:12 +0000
committerDmitri Gribenko <gribozavr@gmail.com>2012-08-06 19:03:12 +0000
commit7d9b51107999c1c1fada7319c4687fe570eb2c0b (patch)
treee433a68cfea61b090e575f2a947514400c1396bf /include
parent38447a40795ef140a5d14ce43e31b60276c8d207 (diff)
Comment parser and sema: remove useless return values
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@161331 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r--include/clang/AST/CommentParser.h23
-rw-r--r--include/clang/AST/CommentSema.h62
2 files changed, 37 insertions, 48 deletions
diff --git a/include/clang/AST/CommentParser.h b/include/clang/AST/CommentParser.h
index 53ea2fcdec..9539c9f54e 100644
--- a/include/clang/AST/CommentParser.h
+++ b/include/clang/AST/CommentParser.h
@@ -55,15 +55,13 @@ class Parser {
/// A stack of additional lookahead tokens.
SmallVector<Token, 8> MoreLATokens;
- SourceLocation consumeToken() {
- SourceLocation Loc = Tok.getLocation();
+ void consumeToken() {
if (MoreLATokens.empty())
L.lex(Tok);
else {
Tok = MoreLATokens.back();
MoreLATokens.pop_back();
}
- return Loc;
}
void putBack(const Token &OldTok) {
@@ -90,19 +88,16 @@ public:
const SourceManager &SourceMgr, DiagnosticsEngine &Diags);
/// Parse arguments for \\param command.
- ParamCommandComment *parseParamCommandArgs(
- ParamCommandComment *PC,
- TextTokenRetokenizer &Retokenizer);
+ void parseParamCommandArgs(ParamCommandComment *PC,
+ TextTokenRetokenizer &Retokenizer);
/// Parse arguments for \\tparam command.
- TParamCommandComment *parseTParamCommandArgs(
- TParamCommandComment *TPC,
- TextTokenRetokenizer &Retokenizer);
-
- BlockCommandComment *parseBlockCommandArgs(
- BlockCommandComment *BC,
- TextTokenRetokenizer &Retokenizer,
- unsigned NumArgs);
+ void parseTParamCommandArgs(TParamCommandComment *TPC,
+ TextTokenRetokenizer &Retokenizer);
+
+ void parseBlockCommandArgs(BlockCommandComment *BC,
+ TextTokenRetokenizer &Retokenizer,
+ unsigned NumArgs);
BlockCommandComment *parseBlockCommand();
InlineCommandComment *parseInlineCommand();
diff --git a/include/clang/AST/CommentSema.h b/include/clang/AST/CommentSema.h
index 114cfc577b..bbb7c94e24 100644
--- a/include/clang/AST/CommentSema.h
+++ b/include/clang/AST/CommentSema.h
@@ -95,44 +95,40 @@ public:
SourceLocation LocEnd,
StringRef Name);
- BlockCommandComment *actOnBlockCommandArgs(
- BlockCommandComment *Command,
- ArrayRef<BlockCommandComment::Argument> Args);
+ void actOnBlockCommandArgs(BlockCommandComment *Command,
+ ArrayRef<BlockCommandComment::Argument> Args);
- BlockCommandComment *actOnBlockCommandFinish(BlockCommandComment *Command,
- ParagraphComment *Paragraph);
+ void actOnBlockCommandFinish(BlockCommandComment *Command,
+ ParagraphComment *Paragraph);
ParamCommandComment *actOnParamCommandStart(SourceLocation LocBegin,
SourceLocation LocEnd,
StringRef Name);
- ParamCommandComment *actOnParamCommandDirectionArg(
- ParamCommandComment *Command,
- SourceLocation ArgLocBegin,
- SourceLocation ArgLocEnd,
- StringRef Arg);
+ void actOnParamCommandDirectionArg(ParamCommandComment *Command,
+ SourceLocation ArgLocBegin,
+ SourceLocation ArgLocEnd,
+ StringRef Arg);
- ParamCommandComment *actOnParamCommandParamNameArg(
- ParamCommandComment *Command,
- SourceLocation ArgLocBegin,
- SourceLocation ArgLocEnd,
- StringRef Arg);
+ void actOnParamCommandParamNameArg(ParamCommandComment *Command,
+ SourceLocation ArgLocBegin,
+ SourceLocation ArgLocEnd,
+ StringRef Arg);
- ParamCommandComment *actOnParamCommandFinish(ParamCommandComment *Command,
- ParagraphComment *Paragraph);
+ void actOnParamCommandFinish(ParamCommandComment *Command,
+ ParagraphComment *Paragraph);
TParamCommandComment *actOnTParamCommandStart(SourceLocation LocBegin,
SourceLocation LocEnd,
StringRef Name);
- TParamCommandComment *actOnTParamCommandParamNameArg(
- TParamCommandComment *Command,
- SourceLocation ArgLocBegin,
- SourceLocation ArgLocEnd,
- StringRef Arg);
+ void actOnTParamCommandParamNameArg(TParamCommandComment *Command,
+ SourceLocation ArgLocBegin,
+ SourceLocation ArgLocEnd,
+ StringRef Arg);
- TParamCommandComment *actOnTParamCommandFinish(TParamCommandComment *Command,
- ParagraphComment *Paragraph);
+ void actOnTParamCommandFinish(TParamCommandComment *Command,
+ ParagraphComment *Paragraph);
InlineCommandComment *actOnInlineCommand(SourceLocation CommandLocBegin,
SourceLocation CommandLocEnd,
@@ -159,11 +155,10 @@ public:
VerbatimBlockLineComment *actOnVerbatimBlockLine(SourceLocation Loc,
StringRef Text);
- VerbatimBlockComment *actOnVerbatimBlockFinish(
- VerbatimBlockComment *Block,
- SourceLocation CloseNameLocBegin,
- StringRef CloseName,
- ArrayRef<VerbatimBlockLineComment *> Lines);
+ void actOnVerbatimBlockFinish(VerbatimBlockComment *Block,
+ SourceLocation CloseNameLocBegin,
+ StringRef CloseName,
+ ArrayRef<VerbatimBlockLineComment *> Lines);
VerbatimLineComment *actOnVerbatimLine(SourceLocation LocBegin,
StringRef Name,
@@ -173,11 +168,10 @@ public:
HTMLStartTagComment *actOnHTMLStartTagStart(SourceLocation LocBegin,
StringRef TagName);
- HTMLStartTagComment *actOnHTMLStartTagFinish(
- HTMLStartTagComment *Tag,
- ArrayRef<HTMLStartTagComment::Attribute> Attrs,
- SourceLocation GreaterLoc,
- bool IsSelfClosing);
+ void actOnHTMLStartTagFinish(HTMLStartTagComment *Tag,
+ ArrayRef<HTMLStartTagComment::Attribute> Attrs,
+ SourceLocation GreaterLoc,
+ bool IsSelfClosing);
HTMLEndTagComment *actOnHTMLEndTag(SourceLocation LocBegin,
SourceLocation LocEnd,