Skip to content

Commit bdeb9e5

Browse files
authored
Merge pull request ethereum#2947 from ethereum/develop
Merge develop into release for 0.4.17.
2 parents d7661dd + a14fc5f commit bdeb9e5

File tree

146 files changed

+4725
-2211
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

146 files changed

+4725
-2211
lines changed

.gitmodules

Lines changed: 0 additions & 3 deletions
This file was deleted.

.travis.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,6 @@ cache:
174174
ccache: true
175175
directories:
176176
- boost_1_57_0
177-
- build
178177
- $HOME/.local
179178

180179
install:
@@ -221,7 +220,7 @@ deploy:
221220
branch:
222221
- develop
223222
- release
224-
- /^v[0-9]/
223+
- /^v\d/
225224
# This is the deploy target for the native build (Linux and macOS)
226225
# which generates ZIPs per commit and the source tarball.
227226
#

CMakeLists.txt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,17 @@ include(EthPolicy)
88
eth_policy()
99

1010
# project name and version should be set after cmake_policy CMP0048
11-
set(PROJECT_VERSION "0.4.16")
11+
set(PROJECT_VERSION "0.4.17")
1212
project(solidity VERSION ${PROJECT_VERSION})
1313

1414
option(SOLC_LINK_STATIC "Link solc executable statically on supported platforms" OFF)
1515

16+
# Setup cccache.
17+
include(EthCcache)
18+
1619
# Let's find our dependencies
1720
include(EthDependencies)
18-
include(deps/jsoncpp.cmake)
21+
include(jsoncpp)
1922

2023
find_package(Threads)
2124

Changelog.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,28 @@
1+
### 0.4.17 (2017-09-21)
2+
3+
Features:
4+
* Assembly Parser: Support multiple assignment (``x, y := f()``).
5+
* Code Generator: Keep a single copy of encoding functions when using the experimental "ABIEncoderV2".
6+
* Code Generator: Partial support for passing ``structs`` as arguments and return parameters (requires ``pragma experimental ABIEncoderV2;`` for now).
7+
* General: Support ``pragma experimental "v0.5.0";`` to activate upcoming breaking changes.
8+
* General: Added ``.selector`` member on external function types to retrieve their signature.
9+
* Optimizer: Add new optimization step to remove unused ``JUMPDEST``s.
10+
* Static Analyzer: Warn when using deprecated builtins ``sha3`` and ``suicide``
11+
(replaced by ``keccak256`` and ``selfdestruct``, introduced in 0.4.2 and 0.2.0, respectively).
12+
* Syntax Checker: Warn if no visibility is specified on contract functions.
13+
* Type Checker: Display helpful warning for unused function arguments/return parameters.
14+
* Type Checker: Do not show the same error multiple times for events.
15+
* Type Checker: Greatly reduce the number of duplicate errors shown for duplicate constructors and functions.
16+
* Type Checker: Warn on using literals as tight packing parameters in ``keccak256``, ``sha3``, ``sha256`` and ``ripemd160``.
17+
* Type Checker: Enforce ``view`` and ``pure``.
18+
* Type Checker: Enforce ``view`` / ``constant`` with error as experimental 0.5.0 feature.
19+
* Type Checker: Enforce fallback functions to be ``external`` as experimental 0.5.0 feature.
20+
21+
Bugfixes:
22+
* ABI JSON: Include all overloaded events.
23+
* Parser: Crash fix related to parseTypeName.
24+
* Type Checker: Allow constant byte arrays.
25+
126
### 0.4.16 (2017-08-24)
227

328
Features:

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# The Solidity Contract-Oriented Programming Language
2-
[![Join the chat at https://gitter.im/ethereum/solidity](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/ethereum/solidity?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
2+
[![Join the chat at https://gitter.im/ethereum/solidity](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/ethereum/solidity?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![Build Status](https://travis-ci.org/ethereum/solidity.svg?branch=develop)](https://travis-ci.org/ethereum/solidity)
33

44
## Useful links
55
To get started you can find an introduction to the language in the [Solidity documentation](https://solidity.readthedocs.org). In the documentation, you can find [code examples](https://solidity.readthedocs.io/en/latest/solidity-by-example.html) as well as [a reference](https://solidity.readthedocs.io/en/latest/solidity-in-depth.html) of the syntax and details on how to write smart contracts.

circle.yml

Lines changed: 44 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,50 @@
11
version: 2
22
jobs:
33
build:
4-
branches:
5-
ignore:
6-
- /.*/
74
docker:
8-
- image: trzeci/emscripten:sdk-tag-1.37.18-64bit
5+
- image: trzeci/emscripten:sdk-tag-1.37.21-64bit
96
steps:
107
- checkout
8+
- run:
9+
name: Install external tests deps
10+
command: |
11+
apt-get -qq update
12+
apt-get -qy install netcat curl
13+
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.4/install.sh | NVM_DIR=/usr/local/nvm bash
14+
- run:
15+
name: Test external tests deps
16+
command: |
17+
export NVM_DIR="/usr/local/nvm"
18+
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
19+
nvm --version
20+
nvm install 6
21+
node --version
22+
npm --version
23+
- run:
24+
name: Init submodules
25+
command: |
26+
git submodule update --init
27+
- restore_cache:
28+
name: Restore Boost build
29+
key: &boost-cache-key emscripten-boost-{{ checksum "scripts/travis-emscripten/install_deps.sh" }}{{ checksum "scripts/travis-emscripten/build_emscripten.sh" }}
30+
- run:
31+
name: Bootstrap Boost
32+
command: |
33+
scripts/travis-emscripten/install_deps.sh
34+
- run:
35+
name: Build
36+
command: |
37+
scripts/travis-emscripten/build_emscripten.sh
38+
- save_cache:
39+
name: Save Boost build
40+
key: *boost-cache-key
41+
paths:
42+
- boost_1_57_0
43+
- run:
44+
name: Test
45+
command: |
46+
. /usr/local/nvm/nvm.sh
47+
scripts/test_emscripten.sh
48+
- store_artifacts:
49+
path: build/solc/soljson.js
50+
destination: soljson.js

cmake/EthCcache.cmake

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Setup ccache.
2+
#
3+
# The ccache is auto-enabled if the tool is found.
4+
# To disable set -DCCACHE=OFF option.
5+
if(NOT DEFINED CMAKE_CXX_COMPILER_LAUNCHER)
6+
find_program(CCACHE ccache DOC "ccache tool path; set to OFF to disable")
7+
if(CCACHE)
8+
set(CMAKE_CXX_COMPILER_LAUNCHER ${CCACHE})
9+
if(COMMAND cotire)
10+
# Change ccache config to meet cotire requirements.
11+
set(ENV{CCACHE_SLOPPINESS} pch_defines,time_macros)
12+
endif()
13+
message(STATUS "[ccache] Enabled: ${CCACHE}")
14+
endif()
15+
endif()

cmake/EthCompilerSettings.cmake

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,6 @@
1414
#
1515
# These settings then end up spanning all POSIX platforms (Linux, OS X, BSD, etc)
1616

17-
# Use ccache if available
18-
find_program(CCACHE_FOUND ccache)
19-
if(CCACHE_FOUND)
20-
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
21-
set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache)
22-
message("Using ccache")
23-
endif(CCACHE_FOUND)
24-
2517
include(CheckCXXCompilerFlag)
2618

2719
check_cxx_compiler_flag(-fstack-protector-strong have_stack_protector_strong)

cmake/jsoncpp.cmake

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
include(ExternalProject)
2+
3+
if (${CMAKE_SYSTEM_NAME} STREQUAL "Emscripten")
4+
set(JSONCPP_CMAKE_COMMAND emcmake cmake)
5+
else()
6+
set(JSONCPP_CMAKE_COMMAND ${CMAKE_COMMAND})
7+
endif()
8+
9+
# Disable implicit fallthrough warning in jsoncpp for gcc >= 7 until the upstream handles it properly
10+
if (("${CMAKE_CXX_COMPILER_ID}" MATCHES "GNU") AND CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 7.0)
11+
set(JSONCCP_EXTRA_FLAGS -Wno-implicit-fallthrough)
12+
else()
13+
set(JSONCCP_EXTRA_FLAGS "")
14+
endif()
15+
16+
set(prefix "${CMAKE_BINARY_DIR}/deps")
17+
set(JSONCPP_LIBRARY "${prefix}/lib/${CMAKE_STATIC_LIBRARY_PREFIX}jsoncpp${CMAKE_STATIC_LIBRARY_SUFFIX}")
18+
set(JSONCPP_INCLUDE_DIR "${prefix}/include")
19+
20+
set(byproducts "")
21+
if(CMAKE_VERSION VERSION_GREATER 3.1)
22+
set(byproducts BUILD_BYPRODUCTS "${JSONCPP_LIBRARY}")
23+
endif()
24+
25+
ExternalProject_Add(jsoncpp-project
26+
PREFIX "${prefix}"
27+
DOWNLOAD_DIR "${CMAKE_SOURCE_DIR}/deps/downloads"
28+
DOWNLOAD_NAME jsoncpp-1.7.7.tar.gz
29+
URL https://github.com/open-source-parsers/jsoncpp/archive/1.7.7.tar.gz
30+
URL_HASH SHA256=087640ebcf7fbcfe8e2717a0b9528fff89c52fcf69fa2a18cc2b538008098f97
31+
CMAKE_COMMAND ${JSONCPP_CMAKE_COMMAND}
32+
CMAKE_ARGS -DCMAKE_INSTALL_PREFIX=<INSTALL_DIR>
33+
-DCMAKE_C_COMPILER=${CMAKE_C_COMPILER}
34+
-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}
35+
# Build static lib but suitable to be included in a shared lib.
36+
-DCMAKE_POSITION_INDEPENDENT_CODE=${BUILD_SHARED_LIBS}
37+
-DJSONCPP_WITH_TESTS=OFF
38+
-DJSONCPP_WITH_PKGCONFIG_SUPPORT=OFF
39+
-DCMAKE_CXX_FLAGS=${JSONCCP_EXTRA_FLAGS}
40+
# Overwrite build and install commands to force Release build on MSVC.
41+
BUILD_COMMAND cmake --build <BINARY_DIR> --config Release
42+
INSTALL_COMMAND cmake --build <BINARY_DIR> --config Release --target install
43+
${byproducts}
44+
)
45+
46+
# Create jsoncpp imported library
47+
add_library(jsoncpp STATIC IMPORTED)
48+
file(MAKE_DIRECTORY ${JSONCPP_INCLUDE_DIR}) # Must exist.
49+
set_property(TARGET jsoncpp PROPERTY IMPORTED_LOCATION ${JSONCPP_LIBRARY})
50+
set_property(TARGET jsoncpp PROPERTY INTERFACE_INCLUDE_DIRECTORIES ${JSONCPP_INCLUDE_DIR})
51+
add_dependencies(jsoncpp jsoncpp-project)

deps

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)