0

for example i have a contract function that returns a contract, can I define an interface that calls that function, but only returns an address?

contract foo {
   ....
   ....
}

contract bar {
   function getFoo() returns (foo);
}

Can I make an interface for bar that just returns an address instead of foo? like so:

contract barInterface {
   function getFoo() returns (address);
}

I can't change bar itself because it's a pre-existing contract

0

... returns (address f) { return address(foo); }

Hope it helps.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.