mirror of
https://github.com/ethereum/solidity
synced 2023-10-03 13:03:40 +00:00
Merge pull request #4837 from chase1745/default-to-unspecified
Rename `Location::Default` to `Location::Unspecified`
This commit is contained in:
@@ -517,7 +517,7 @@ set<VariableDeclaration::Location> VariableDeclaration::allowedDataLocations() c
|
||||
using Location = VariableDeclaration::Location;
|
||||
|
||||
if (!hasReferenceOrMappingType() || isStateVariable() || isEventParameter())
|
||||
return set<Location>{ Location::Default };
|
||||
return set<Location>{ Location::Unspecified };
|
||||
else if (isStateVariable() && isConstant())
|
||||
return set<Location>{ Location::Memory };
|
||||
else if (isExternalCallableParameter())
|
||||
@@ -546,7 +546,7 @@ set<VariableDeclaration::Location> VariableDeclaration::allowedDataLocations() c
|
||||
}
|
||||
else
|
||||
// Struct members etc.
|
||||
return set<Location>{ Location::Default };
|
||||
return set<Location>{ Location::Unspecified };
|
||||
}
|
||||
|
||||
TypePointer VariableDeclaration::type() const
|
||||
|
||||
@@ -655,7 +655,7 @@ private:
|
||||
class VariableDeclaration: public Declaration
|
||||
{
|
||||
public:
|
||||
enum Location { Default, Storage, Memory, CallData };
|
||||
enum Location { Unspecified, Storage, Memory, CallData };
|
||||
|
||||
VariableDeclaration(
|
||||
SourceLocation const& _sourceLocation,
|
||||
@@ -666,7 +666,7 @@ public:
|
||||
bool _isStateVar = false,
|
||||
bool _isIndexed = false,
|
||||
bool _isConstant = false,
|
||||
Location _referenceLocation = Location::Default
|
||||
Location _referenceLocation = Location::Unspecified
|
||||
):
|
||||
Declaration(_sourceLocation, _name, _visibility),
|
||||
m_typeName(_type),
|
||||
|
||||
@@ -739,7 +739,7 @@ string ASTJsonConverter::location(VariableDeclaration::Location _location)
|
||||
{
|
||||
switch (_location)
|
||||
{
|
||||
case VariableDeclaration::Location::Default:
|
||||
case VariableDeclaration::Location::Unspecified:
|
||||
return "default";
|
||||
case VariableDeclaration::Location::Storage:
|
||||
return "storage";
|
||||
|
||||
Reference in New Issue
Block a user