Giter VIP home page Giter VIP logo

Comments (6)

duaraghav8 avatar duaraghav8 commented on June 16, 2024 1

Ahh! When I test the whole code in a single file, it doesn't pose any errors.

You must've declared IMyContract in 1 file, and MyContract in another.
At a time, Solium lints only a single file, so it is not informed whether you are using the variable in some other file or not.

This needs fixing.

from ethlint.

duaraghav8 avatar duaraghav8 commented on June 16, 2024 1

this issue no longer persists since solium does not check state variables for usage any more.
feel free to re-open in case you face this (or something similar).

from ethlint.

duaraghav8 avatar duaraghav8 commented on June 16, 2024

I'm unable to reproduce the error with the code you've posted. In fact, when I comment out someAddress = X;, then it gives me the var-not-used error (as expected), but when its not commented out, there is no error.

Could you tell me which version you're using? (solium --version)

from ethlint.

elenadimitrova avatar elenadimitrova commented on June 16, 2024

[email protected]

from ethlint.

elenadimitrova avatar elenadimitrova commented on June 16, 2024

I just installed 0.1.8 and it is still throwing the error

---------------------------------------------------------------------------------------
FILE:   /contracts/IMyContract.sol
---------------------------------------------------------------------------------------

[WARNING] At line: 1, column: 0 -> Contract name 'IMyContract' doesn't follow the CamelCase notation

[ERROR] At line: 3, column: 2 -> Variable 'someAddress' is declared but never used.

Are you testing these in 2 separate files or as declared in 1?

from ethlint.

duaraghav8 avatar duaraghav8 commented on June 16, 2024

Putting this link here for my own (future) reference
https://eslint.org/docs/rules/no-unused-vars#exported

from ethlint.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.