mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Use consistent syntax for Bash function declarations
This commit is contained in:
@@ -154,7 +154,7 @@ function ask_expectation_update
|
||||
|
||||
# General helper function for testing SOLC behaviour, based on file name, compile opts, exit code, stdout and stderr.
|
||||
# An failure is expected.
|
||||
function test_solc_behaviour()
|
||||
function test_solc_behaviour
|
||||
{
|
||||
local filename="${1}"
|
||||
local solc_args
|
||||
@@ -288,7 +288,7 @@ EOF
|
||||
}
|
||||
|
||||
|
||||
function test_solc_assembly_output()
|
||||
function test_solc_assembly_output
|
||||
{
|
||||
local input="${1}"
|
||||
local expected="${2}"
|
||||
|
||||
@@ -10,11 +10,11 @@ REPO_ROOT=$(cd "$(dirname "$0")/.." && pwd)
|
||||
|
||||
if [ "$CIRCLECI" ]
|
||||
then
|
||||
function printTask() { echo "$(tput bold)$(tput setaf 2)$1$(tput setaf 7)"; }
|
||||
function printError() { echo "$(tput setaf 1)$1$(tput setaf 7)"; }
|
||||
function printTask { echo "$(tput bold)$(tput setaf 2)$1$(tput setaf 7)"; }
|
||||
function printError { echo "$(tput setaf 1)$1$(tput setaf 7)"; }
|
||||
else
|
||||
function printTask() { echo "$(tput bold)$(tput setaf 2)$1$(tput sgr0)"; }
|
||||
function printError() { echo "$(tput setaf 1)$1$(tput sgr0)"; }
|
||||
function printTask { echo "$(tput bold)$(tput setaf 2)$1$(tput sgr0)"; }
|
||||
function printError { echo "$(tput setaf 1)$1$(tput sgr0)"; }
|
||||
fi
|
||||
|
||||
printTask "Checking docs examples style"
|
||||
|
||||
@@ -187,7 +187,8 @@ function run_test
|
||||
$test_fn
|
||||
}
|
||||
|
||||
function optimizer_settings_for_level {
|
||||
function optimizer_settings_for_level
|
||||
{
|
||||
local level="$1"
|
||||
|
||||
case "$level" in
|
||||
@@ -201,7 +202,8 @@ function optimizer_settings_for_level {
|
||||
esac
|
||||
}
|
||||
|
||||
function truffle_compiler_settings {
|
||||
function truffle_compiler_settings
|
||||
{
|
||||
local solc_path="$1"
|
||||
local level="$2"
|
||||
local evm_version="$3"
|
||||
|
||||
@@ -15,7 +15,7 @@ FILETMP=$(mktemp -d)
|
||||
cd "$FILETMP" || exit 1
|
||||
|
||||
|
||||
function testFile()
|
||||
function testFile
|
||||
{
|
||||
set +e
|
||||
ALLOUTPUT=$($SOLC --combined-json ast --pretty-json "$@" --stop-after parsing 2>&1)
|
||||
|
||||
Reference in New Issue
Block a user