mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Changelog entry and small fixes.
This commit is contained in:
parent
6172590b87
commit
62492b67e7
@ -1,6 +1,7 @@
|
|||||||
### 0.4.5 (unreleased)
|
### 0.4.5 (unreleased)
|
||||||
|
|
||||||
Features:
|
Features:
|
||||||
|
* Function types
|
||||||
* Do-while loops: support for a C-style do{<block>}while(<expr>); control structure
|
* Do-while loops: support for a C-style do{<block>}while(<expr>); control structure
|
||||||
* Inline assembly: support ``invalidJumpLabel`` as a jump label.
|
* Inline assembly: support ``invalidJumpLabel`` as a jump label.
|
||||||
* Type checker: now more eagerly searches for a common type of an inline array with mixed types
|
* Type checker: now more eagerly searches for a common type of an inline array with mixed types
|
||||||
|
@ -228,8 +228,13 @@ bool ASTJsonConverter::visit(UserDefinedTypeName const& _node)
|
|||||||
|
|
||||||
bool ASTJsonConverter::visit(FunctionTypeName const& _node)
|
bool ASTJsonConverter::visit(FunctionTypeName const& _node)
|
||||||
{
|
{
|
||||||
|
string visibility = "internal";
|
||||||
|
if (_node.visibility() == Declaration::Visibility::External)
|
||||||
|
visibility = "external";
|
||||||
|
|
||||||
addJsonNode(_node, "FunctionTypeName", {
|
addJsonNode(_node, "FunctionTypeName", {
|
||||||
make_pair("payable", _node.isPayable()),
|
make_pair("payable", _node.isPayable()),
|
||||||
|
make_pair("visibility", visibility),
|
||||||
make_pair("constant", _node.isDeclaredConst())
|
make_pair("constant", _node.isDeclaredConst())
|
||||||
});
|
});
|
||||||
return true;
|
return true;
|
||||||
|
@ -2077,12 +2077,10 @@ TypePointer FunctionType::encodingType() const
|
|||||||
|
|
||||||
TypePointer FunctionType::interfaceType(bool /*_inLibrary*/) const
|
TypePointer FunctionType::interfaceType(bool /*_inLibrary*/) const
|
||||||
{
|
{
|
||||||
if (m_location != Location::External && m_location != Location::Internal)
|
if (m_location == Location::External)
|
||||||
return TypePointer();
|
|
||||||
if (m_location != Location::External)
|
|
||||||
return TypePointer();
|
|
||||||
else
|
|
||||||
return make_shared<IntegerType>(8 * storageBytes());
|
return make_shared<IntegerType>(8 * storageBytes());
|
||||||
|
else
|
||||||
|
return TypePointer();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool FunctionType::canTakeArguments(TypePointers const& _argumentTypes, TypePointer const& _selfType) const
|
bool FunctionType::canTakeArguments(TypePointers const& _argumentTypes, TypePointer const& _selfType) const
|
||||||
|
Loading…
Reference in New Issue
Block a user