fix(solidity) (#164)

* fix(solidity)

v0.8.18 removes `solidity-upgrade`, which we were already removing.

* patch new cpp file
This commit is contained in:
Jacob Heider 2023-02-01 18:34:15 -05:00 committed by GitHub
parent af1e9ca1b2
commit 159c3a152b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 24 additions and 1 deletions

View file

@ -0,0 +1,12 @@
diff --color=auto -ru a/libsolidity/lsp/DocumentHoverHandler.cpp b/libsolidity/lsp/DocumentHoverHandler.cpp
--- a/libsolidity/lsp/DocumentHoverHandler.cpp 2023-02-01 17:33:07
+++ b/libsolidity/lsp/DocumentHoverHandler.cpp 2023-02-01 17:32:26
@@ -63,7 +63,7 @@
auto const [sourceUnitName, lineColumn] = HandlerBase(*this).extractSourceUnitNameAndLineColumn(_args);
auto const [sourceNode, sourceOffset] = m_server.astNodeAndOffsetAtSourceLocation(sourceUnitName, lineColumn);
- MarkdownBuilder markdown{};
+ MarkdownBuilder markdown = {stringstream(ios_base::in)};
auto rangeToHighlight = toRange(sourceNode->location());
// Try getting the type definition of the underlying AST node, if available.

View file

@ -23,12 +23,23 @@ build:
cmake.org: 3
freedesktop.org/pkg-config: ^0.29
git-scm.org: 2
crates.io/semverator: '*'
gnu.org/patch: '*'
working-directory: build
script: |
if semverator satisfies ^0.8.18 {{version}}; then
# New libsolidity/lsb/DocumentHoverHandler.cpp doesn't like some versions of clang
# (default argument issue)
patch -p1 -d.. <../props/clang-error.diff
fi
cmake .. $ARGS
make --jobs {{hw.concurrency}}
make install
rm {{prefix}}/bin/solidity-upgrade
if semverator lt {{version}} 0.8.18; then
rm {{prefix}}/bin/solidity-upgrade
fi
test:
make test
env: