diff --git a/libsolidity/parsing/DocStringParser.cpp b/libsolidity/parsing/DocStringParser.cpp index d058d5569..d9588e5ca 100644 --- a/libsolidity/parsing/DocStringParser.cpp +++ b/libsolidity/parsing/DocStringParser.cpp @@ -72,7 +72,7 @@ bool DocStringParser::parse(string const& _docString, ErrorReporter& _errorRepor auto tagNameEndPos = firstWhitespaceOrNewline(tagPos, end); if (tagNameEndPos == end) { - appendError("End of tag " + string(tagPos, tagNameEndPos) + "not found"); + appendError("End of tag " + string(tagPos, tagNameEndPos) + " not found"); break; } diff --git a/test/libsolidity/syntaxTests/docstring_empty_description.sol b/test/libsolidity/syntaxTests/natspec/docstring_empty_description.sol similarity index 100% rename from test/libsolidity/syntaxTests/docstring_empty_description.sol rename to test/libsolidity/syntaxTests/natspec/docstring_empty_description.sol diff --git a/test/libsolidity/syntaxTests/natspec/docstring_empty_tag.sol b/test/libsolidity/syntaxTests/natspec/docstring_empty_tag.sol new file mode 100644 index 000000000..9a28143a1 --- /dev/null +++ b/test/libsolidity/syntaxTests/natspec/docstring_empty_tag.sol @@ -0,0 +1,6 @@ +contract C { + /// @param + function vote(uint id) public; +} +// ---- +// DocstringParsingError: End of tag @param not found