abi-gen/Py: fix hanging indent for return val doc

The update to the fixture contract's artifact added a bunch of
`internalType` stuff.  I'm not sure where that came from.  Maybe
newly generated by the latest version of solc?
This commit is contained in:
F. Eugene Aumson
2019-08-13 11:24:00 -04:00
parent cdf0aa27e4
commit e5c07ff0c5
5 changed files with 104 additions and 18 deletions

View File

@@ -181,7 +181,9 @@ function registerPythonHelpers(): void {
Handlebars.registerHelper(
'makeReturnDocstringRole',
(description: string, indent: number) =>
new Handlebars.SafeString(utils.wrapPythonDocstringRole(`:returns: ${description}`, indent)),
new Handlebars.SafeString(
utils.wrapPythonDocstringRole(`:returns: ${description.replace(/ +/g, ' ')}`, indent),
),
);
Handlebars.registerHelper(
'makeEventParameterDocstringRole',

File diff suppressed because one or more lines are too long

View File

@@ -496,7 +496,7 @@ export class AbiGenDummyContract extends BaseContract {
* @param v some v, recovery id
* @param r ECDSA r output
* @param s ECDSA s output
* @returns the signerAddress that created this signature
* @returns the signerAddress that created this signature. this line too is super long in order to demonstrate the proper hanging indentation in generated code.
*/
async callAsync(
hash: string,

File diff suppressed because one or more lines are too long

View File

@@ -86,7 +86,7 @@ contract AbiGenDummy
/// @param v some v, recovery id
/// @param r ECDSA r output
/// @param s ECDSA s output
/// @return the signerAddress that created this signature
/// @return the signerAddress that created this signature. this line too is super long in order to demonstrate the proper hanging indentation in generated code.
function ecrecoverFn(bytes32 hash, uint8 v, bytes32 r, bytes32 s)
public
pure
@@ -179,7 +179,7 @@ contract AbiGenDummy
function overloadedMethod(int a) public pure {}
function overloadedMethod(string memory a) public pure {}
// begin tests for `decodeTransactionData`, `decodeReturnData`
/// @dev complex input is dynamic and more difficult to decode than simple input.
@@ -196,7 +196,7 @@ contract AbiGenDummy
bytes ipsum;
string dolor;
}
/// @dev Tests decoding when both input and output are empty.
function noInputNoOutput()
public