aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity
diff options
context:
space:
mode:
authorVoR0220 <rj@erisindustries.com>2017-01-11 23:03:41 +0800
committerVoR0220 <rj@erisindustries.com>2017-01-11 23:03:41 +0800
commite02270bbb4a9f151bc25e0e0f96f1e4505542de5 (patch)
tree8b0548d29988ae007df417c2b0e5608850bfaf07 /libsolidity
parent8ace851831f63035174ae086bb415a0d2efb8277 (diff)
downloaddexon-solidity-e02270bbb4a9f151bc25e0e0f96f1e4505542de5.tar
dexon-solidity-e02270bbb4a9f151bc25e0e0f96f1e4505542de5.tar.gz
dexon-solidity-e02270bbb4a9f151bc25e0e0f96f1e4505542de5.tar.bz2
dexon-solidity-e02270bbb4a9f151bc25e0e0f96f1e4505542de5.tar.lz
dexon-solidity-e02270bbb4a9f151bc25e0e0f96f1e4505542de5.tar.xz
dexon-solidity-e02270bbb4a9f151bc25e0e0f96f1e4505542de5.tar.zst
dexon-solidity-e02270bbb4a9f151bc25e0e0f96f1e4505542de5.zip
fixed unused filepath bug
Signed-off-by: VoR0220 <rj@erisindustries.com>
Diffstat (limited to 'libsolidity')
-rw-r--r--libsolidity/interface/CompilerStack.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/libsolidity/interface/CompilerStack.cpp b/libsolidity/interface/CompilerStack.cpp
index 094360a3..30abad07 100644
--- a/libsolidity/interface/CompilerStack.cpp
+++ b/libsolidity/interface/CompilerStack.cpp
@@ -508,7 +508,6 @@ string CompilerStack::applyRemapping(string const& _path, string const& _context
return std::equal(_a.begin(), _a.end(), _b.begin());
};
- using filepath = boost::filesystem::path;
size_t longestPrefix = 0;
size_t longestContext = 0;
string longestPrefixTarget;
@@ -524,7 +523,7 @@ string CompilerStack::applyRemapping(string const& _path, string const& _context
if (!isPrefixOf(contextFileString, _context))
continue;
// Skip if we already have a closer match.
- if (longestPrefix > 0 && prefixFileString.length() < longestPrefix)
+ if (prefixFileString.length() < longestPrefix)
continue;
// Skip if the prefix does not match.
if (!isPrefixOf(prefixFileString, _path))