Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Deep copy of arrays #99

Open
dddejan opened this issue Oct 10, 2019 · 2 comments
Open

Deep copy of arrays #99

dddejan opened this issue Oct 10, 2019 · 2 comments
Labels
enhancement New feature or request

Comments

@dddejan
Copy link
Member

dddejan commented Oct 10, 2019

pragma solidity >=0.5.0;

contract Test {
  struct S {
    int x;
  }
  S[] m_a;
  function test() external view {
    S[] memory a;
    a = m_a;
  }
}

Gives

solc-verify.py Test.sol --output .
Error while running verifier, details:
Parsing ./Test.sol.bpl
./Test.sol.bpl(42,85): Error: right-hand side in map store with wrong type: struct_storage_S#4_arr_type (expected: address_struct_memory_S#4_arr_type)
1 type checking errors detected in ./Test.sol.bpl

It's not clear how we support this. More meaningful error message would be good.

@hajduakos
Copy link
Member

I agree. Will add a more meaningful error message until it gets supported

@hajduakos
Copy link
Member

Meaningful error message in 60a0400

@dddejan dddejan added the enhancement New feature or request label Oct 11, 2019
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants