This error refers to the bad formatting of Doxygen tags within DocString comments (commonly known as NatSpec Format comments).
If you do not format these tags value correctly, the Solidity compiler " moans " and does not compile (even if the rest of the code is correct unfortunately !).
Solving your problem
NB: Your question is really old and I couldn't find the original source code with the syntax error.
I will use a modified version of Oleg Kondrahanov code example to explain (while removing constant
keyword which is deprecated.
The problem in your code does not come from the _to.call.value(_value)(_data);
(This is just a Warning and you can still compile with Warnings in Solidity). Rather the problem comes from how you document the parameter using doxygen tags in NatSpec.
In your case, you must include the name of the function parameter after the @param
tag (not the type).
Change it from this :
/**
* Calculate the current price for buy in amount.
*
* REPLACE THIS SECTION
* | |
* v v
* @param {uint amount} Buy-in value in wei.
*/
function calculatePrice(uint amount) public pure returns (uint) {
// Do something
}
To this :
/**
* Calculate the current price for buy in amount.
*
* WITH THIS
* | |
* v v
* @param amount Buy-in value in wei.
*/
function calculatePrice(uint amount) public pure returns (uint) {
// Do something
}
So after the @param
doxygen tag, you always mention the variable name (As opposed to @return
where you mention the variable type. So the format is like this :
/**
* @param _charity The ethereum address of the charity you want to donate
* @param _amount The amount in Wei to donate to the charity
* @return bool returns true if success
*/
function donateEther(address _charity, uint _amount) public pure returns (bool) {
// your code here
}
What are NatSpec comments ?
In the former Remix IDE, you could see the difference between Standard Solidity comments vs Natspec comments by their colour. See the picture below :

Basically, NatSpec comments are used for two purposes. When you compile a Solidity contract with the solc
compiler via the CLI, you can specify one the following two flags (or both), to generate two documentation file (in JSON format):
solc <file_name.sol> --devdoc
: generates Developer documentation
solc <file_name.sol> --userdoc
: generates User documentation
Note that this does not create a separate file ! But just output the documentation in JSON format in your CLI. See the Solidity doc
Doxygen tags available
Doxygen tags available in Solidity include @title
, @author
, @notice
, @dev
, @param
and @return
.
Only the @notice
tag can be used to generate custom message on UI (when a user commit interact with a smart contracts).
Example :
/// @notice Thank you for your donation, you are about to send `_value / 10**18` Ether to the charity address `_address`.
/// @param _value The amount of ether you want to donate
/// @param _charity The Ethereum address of the charity
function donateEther(address _charity, uint _amount) external returns (bool) {
// your code here
}
Assuming the example we would send 0.34 ethers
(currently ≈ 10 USD) to address 0x7a84B6d2B1A1021df402437712AaE717472e829F
, the example code above would generate a message like this on the UI when you send the transaction :
Thank you for your donation, you are about to send 0.34 ethers
to the charity address 0x7a84B6d2B1A1021df402437712AaE717472e829F