Comments (5)
Yes, that's a good idea. In the meantime, you can always refer to Clang-Format Style Options to see how to enable/disable features in the clang-format binary itself.
from clangformat-xcode.
To answer whether it does this… it doesn't specify it, but perhaps this is the default in the upstream binary?
from clangformat-xcode.
It's a bit of a mistery to me what's actually going on here. The "official" clang format plugin for visual studio has explicit mention of a -sort-includes parameter given:
https://github.com/llvm-mirror/clang/blob/master/tools/clang-format-vs/ClangFormat/ClangFormatPackage.cs#L259
I can't seem to find that in the sources here (maybe i'm not looking well enough?). I wonder if behavior is different between platforms, or if it's just a matter of which version you use.
from clangformat-xcode.
This is just an Xcode plugin that calls through to the clangformat
binary. If you've got a more recent version installed with support for sorting includes, and your configuration specifies it, it will be used (I believe the option appeared in Clang 3.8).
This plugin is not clang format, so there wouldn't be any mention of a specific config option here.
from clangformat-xcode.
It was my understanding however that it's disabled by default on the command-line. I'm trying to figure out what's causing it to get enabled. My configuration file has no mention of this.
I found this from chromium:
https://codereview.chromium.org/1616263006
Where they mention that header sorting is disabled if the Chromium style is used, I guess possible through BasedOnStyle: Chromium
in the config.
There seems to be a lot of scattered information about this topic all over the place with no clear consensus about the actual default behavior of this.
from clangformat-xcode.
Related Issues (20)
- Just FYI – I've created AnyFormat plugin based on your ClangFormat
- Problems with Xcode 7.3
- Disable plugin if selected format from missing File
- Update clang-format (wrong Linux configuration)
- 中文字符串显示不正确 HOT 4
- An error occurred when dealing with Chinese
- Cannot install on Xcode 8 HOT 4
- How to install? HOT 2
- Create home-brew cask for Xcode8 App HOT 1
- XCode 9 support HOT 17
- KeepEmptyLinesAtTheStartOfBlocks does not supported
- Which rule to use for C11 _Generic? HOT 2
- XCode 9 support HOT 1
- Is this still alive? HOT 2
- do you support xcode 11 HOT 2
- About #ifndef
- How to install ? http://alcatraz.io/ not available HOT 3
- integrate clang-tidy with this plugin.
- is this repo still in maintain stage?
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 clangformat-xcode.