Commit 0fe67a20 by github-actions

Merge upstream openzeppelin-contracts into upstream-patched

parents 6768d2ac 3d2e5c03
...@@ -23,5 +23,5 @@ contract Create2Impl { ...@@ -23,5 +23,5 @@ contract Create2Impl {
return Create2.computeAddress(salt, codeHash, deployer); return Create2.computeAddress(salt, codeHash, deployer);
} }
receive() payable external {} receive() external payable {}
} }
...@@ -15,7 +15,7 @@ contract DummyImplementation { ...@@ -15,7 +15,7 @@ contract DummyImplementation {
value = 10; value = 10;
} }
function initializePayable() payable public { function initializePayable() public payable {
value = 100; value = 100;
} }
...@@ -23,7 +23,7 @@ contract DummyImplementation { ...@@ -23,7 +23,7 @@ contract DummyImplementation {
value = _value; value = _value;
} }
function initializePayable(uint256 _value) payable public { function initializePayable(uint256 _value) public payable {
value = _value; value = _value;
} }
...@@ -47,7 +47,7 @@ contract DummyImplementation { ...@@ -47,7 +47,7 @@ contract DummyImplementation {
} }
contract DummyImplementationV2 is DummyImplementation { contract DummyImplementationV2 is DummyImplementation {
function migrate(uint256 newVal) payable public { function migrate(uint256 newVal) public payable {
value = newVal; value = newVal;
} }
......
...@@ -60,7 +60,7 @@ abstract contract Proxy { ...@@ -60,7 +60,7 @@ abstract contract Proxy {
* @dev Fallback function that delegates calls to the address returned by `_implementation()`. Will run if no other * @dev Fallback function that delegates calls to the address returned by `_implementation()`. Will run if no other
* function in the contract matches the call data. * function in the contract matches the call data.
*/ */
fallback () payable external { fallback () external payable {
_fallback(); _fallback();
} }
...@@ -68,7 +68,7 @@ abstract contract Proxy { ...@@ -68,7 +68,7 @@ abstract contract Proxy {
* @dev Fallback function that delegates calls to the address returned by `_implementation()`. Will run if call data * @dev Fallback function that delegates calls to the address returned by `_implementation()`. Will run if call data
* is empty. * is empty.
*/ */
receive () payable external { receive () external payable {
_fallback(); _fallback();
} }
......
This source diff could not be displayed because it is too large. You can view the blob instead.
const path = require('path');
const bre = require('@nomiclabs/buidler');
const { Compiler } = require('@nomiclabs/buidler/internal/solidity/compiler');
const compiler = new Compiler(
bre.config.solc.version,
path.join(bre.config.paths.cache, 'compilers'),
);
module.exports = Object.assign(compiler.getSolc(), { __esModule: true });
...@@ -9,5 +9,12 @@ if [ ! -d node_modules ]; then ...@@ -9,5 +9,12 @@ if [ ! -d node_modules ]; then
fi fi
rm -rf "$OUTDIR" rm -rf "$OUTDIR"
solidity-docgen -t docs -o "$OUTDIR" -e contracts/mocks,contracts/examples --output-structure readmes
solidity-docgen \
-t docs \
-o "$OUTDIR" \
-e contracts/mocks,contracts/examples \
--output-structure readmes \
--solc-module scripts/prepare-docs-solc.js
node scripts/gen-nav.js "$OUTDIR" > "$OUTDIR/../nav.adoc" node scripts/gen-nav.js "$OUTDIR" > "$OUTDIR/../nav.adoc"
## Testing ## Testing
Unit test are critical to the OpenZeppelin framework. They help ensure code quality and mitigate against security vulnerabilities. The directory structure within the `/test` directory corresponds to the `/contracts` directory. OpenZeppelin uses Truffle testing framework(based on the Mocha JavaScript testing framework) and the Chai assertion library. To learn more about how tests are structured, please reference OpenZeppelin’s Testing Guide. Unit test are critical to the OpenZeppelin framework. They help ensure code quality and mitigate against security vulnerabilities. The directory structure within the `/test` directory corresponds to the `/contracts` directory.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment