solc now in ethereum, fixes solc path setting; setSolc() didnt work

This commit is contained in:
zelig
2015-05-20 02:04:52 +01:00
parent f9abcee0f9
commit 22b694ee1e
6 changed files with 26 additions and 15 deletions

View File

@ -66,9 +66,6 @@ type XEth struct {
// regmut sync.Mutex
// register map[string][]*interface{} // TODO improve return type
solcPath string
solc *compiler.Solidity
agent *miner.RemoteAgent
}
@ -379,17 +376,12 @@ func (self *XEth) Accounts() []string {
// accessor for solidity compiler.
// memoized if available, retried on-demand if not
func (self *XEth) Solc() (*compiler.Solidity, error) {
var err error
if self.solc == nil {
self.solc, err = compiler.New(self.solcPath)
}
return self.solc, err
return self.backend.Solc()
}
// set in js console via admin interface or wrapper from cli flags
func (self *XEth) SetSolc(solcPath string) (*compiler.Solidity, error) {
self.solcPath = solcPath
self.solc = nil
self.backend.SetSolc(solcPath)
return self.Solc()
}