Comments (5)
It can still be reproduced on Emacs29.
Adding a semicolon after struct and enum can correct indentation, but it cannot be compiled.
from emacs-solidity.
Hey @robmyers thank you for the bug report and apologies for the late response!
So I tried to reproduce what you are saying with the following program:
contract foo {
struct boo {
uint256 a;
}
function funA() {
return;
}
}
But the indentation does not appear like in your screenshot. How did you automatically ident? By pressing TAB?
My c/c++ code setup which also applies in solidity is here:
https://github.com/LefterisJP/.emacs/blob/90d542d8ee0ddc68a58fd1e2318b694a3dd7d5f5/lk/cstyle-setup.el#L18-L79
from emacs-solidity.
Thank you for looking at this.
The embarrassing outcome of a long process of discovery is that this is an issue with emacs 27 in git. I reverted to emacs 26 and everything is fine.
My apologies for not catching that before asking.
from emacs-solidity.
@rheaplex , I am running into this issue with bleeding-edge emacs 28. Do you recall what the causative issue was in emacs27?
from emacs-solidity.
Check out #72 (comment).
from emacs-solidity.
Related Issues (20)
- swiper/solidity-mode incompatibility HOT 5
- Does not work HOT 5
- parent mode is c-mode in `define-derived-mode` HOT 2
- Unable to make `solidity-flycheck-solc` work HOT 26
- Create a test suite
- Flycheck Gets Stuck at Import HOT 7
- solc `--old-reporter` flag removed in solc 0.8.0 HOT 1
- change indent in solidity mode HOT 2
- el-get-install can't install the package, Ubuntu 20.04 HOT 1
- melpa instruction needs more details
- Gracefully indenting structs and assembly blocks. HOT 14
- solidity-flycheck requires el package to be included in source, otherwise does not work HOT 3
- Constructor body idents too many levels HOT 1
- Keywords inside a string always bolded and colored HOT 2
- [request] lsp mode support HOT 7
- [request] Port Consensys' vscode solidity auditor plugin
- Does this work in Windows
- `remove-if-not` function definition is void
- Default indentation doesn't look right to me HOT 1
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 emacs-solidity.