I received the error message UnimplementedFeatureError: Only byte arrays can be encoded from calldata currently
from the compiler, but without any reference to a file or line.
In a big project, and with a lot of changes, this made the source difficult to find.
The code that caused it ultimately was of this form:
pragma solidity >0.5.0;
pragma experimental ABIEncoderV2;
contract Foo {
constructor(address[] memory _addrs) public {}
}
contract FooFactory {
function createInstance(address[] calldata _addrs) external {
new Foo(_addrs);
}
}