Andre Eisenbach | fe28047 | 2016-09-14 14:32:49 -0700 | [diff] [blame] | 1 | # |
Jakub Pawlowski | 3b10fdd | 2017-09-18 09:00:20 -0700 | [diff] [blame] | 2 | # Copyright 2016 The Android Open Source Project |
Andre Eisenbach | fe28047 | 2016-09-14 14:32:49 -0700 | [diff] [blame] | 3 | # |
| 4 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | # you may not use this file except in compliance with the License. |
| 6 | # You may obtain a copy of the License at |
| 7 | # |
| 8 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | # |
| 10 | # Unless required by applicable law or agreed to in writing, software |
| 11 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | # See the License for the specific language governing permissions and |
| 14 | # limitations under the License. |
| 15 | # |
| 16 | |
| 17 | # |
| 18 | # Below are some minor deviations from the default Google style to |
| 19 | # accommodate for handling of the large legacy code base. |
| 20 | # |
| 21 | |
William Escande | 7b2ca83 | 2024-06-21 18:52:47 +0000 | [diff] [blame] | 22 | # AOSP is based on google style with some modification commented below |
Andre Eisenbach | fe28047 | 2016-09-14 14:32:49 -0700 | [diff] [blame] | 23 | BasedOnStyle: Google |
William Escande | 7b2ca83 | 2024-06-21 18:52:47 +0000 | [diff] [blame] | 24 | |
| 25 | --- |
| 26 | Language: Cpp |
| 27 | # AOSP ask for 4, but we are not ready to touch every single line |
| 28 | # IndentWidth: 4 # vs 2 |
| 29 | ColumnLimit: 100 # vs 80 |
| 30 | ContinuationIndentWidth: 8 # vs 4 |
| 31 | AccessModifierOffset: -2 # vs -1 Should be -4 when updating IndentWidth to 4 |
| 32 | Standard: c++20 # vs Auto |
| 33 | AllowShortIfStatementsOnASingleLine: Never # vs WithoutElse |
| 34 | AllowShortLoopsOnASingleLine: false # vs true |
William Escande | 2bf4c77 | 2024-06-22 15:41:53 -0700 | [diff] [blame] | 35 | # AOSP suggest 1, but ask to follow clang-format settings. CppLint ask for 2 |
| 36 | # SpacesBeforeTrailingComments: 1 # vs 2 |
William Escande | 7b2ca83 | 2024-06-21 18:52:47 +0000 | [diff] [blame] | 37 | |
| 38 | # Allow clang-format to automatically fix more things |
| 39 | RemoveSemicolon: true |
| 40 | InsertBraces: true |
| 41 | RemoveParentheses: ReturnStatement |
| 42 | |
| 43 | --- |
| 44 | Language: Java |
| 45 | # Java format is handled by google-java-format |
| 46 | DisableFormat: true |