Comments (6)
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.
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.
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.
from ethlint.
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.
Putting this link here for my own (future) reference
https://eslint.org/docs/rules/no-unused-vars#exported
from ethlint.
Related Issues (20)
- Inconsistent behavior of indentation rule for abstract functions HOT 4
- max-len rule doesn't apply in certain cases HOT 1
- no-empty-blocks shouldn't flag empty contract body in an inherited contract
- CLI: add option to list all available lint rules
- Update security rules to follow new best practices for transferring value HOT 3
- Wrong indentation on ternary operator parentheses
- Linter complains on assembly for loop syntax
- --fix flag does not fix HOT 2
- “Consider using 'transfer' in place of 'call.value()” is a false error message HOT 1
- Support abstract contracts. HOT 5
- ethlint dependecies secuirty issues
- Syntax error when using array slice on a bytes datatype HOT 1
- Wrong error message for `msg.sender.call{value: amount}("");`
- .soliumignore doesn't ignore files/dirs listed
- yarn audit fail: 4 vulnerabilities found
- Multi-literal strings support
- Linter complain on try/catch syntax
- Linter complain on syntax to call `create2`
- False positive on interface inheriting from another interface
- Feature Request: no-unused-imports
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ethlint.