본문 바로가기
Dev Error

Solidity)솔리디티 Visibility for constructor is ignored. If you want the contract to be non-deployable, making it "abstract" is sufficient.

by 개발이 체질인 나그네 2022. 4. 6.
반응형

 

 

Visibility for constructor is ignored. 
If you want the contract to be non-deployable, making it "abstract" is sufficient.

위와 같은 애러가 났다.

 

-원인 :

생성자(constructor)의 가시성은 무시가 됩니다.

때문에 컨트랙트를 배포 할 수 없도록 하기위해선 "abstract"를 선언하거나

배포를 하기 위해선 아무것도 선언하지 않으면 됩니다.

 

- 해결 :

생성자(constructor)에서 배포를 할 경우, Public 지우고 그냥 Deploy하면 됩니다.

배포를 못하기 하려면 Public자리에 abstract를 넣으면 됩니다.

반응형

댓글