<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/58055>58055</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            clang format header file guessIsObjC error
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          xiaoyur347
      </td>
    </tr>
</table>

<pre>
    I use clang-format to parse my cpp/header file and meet the following error:
Error parsing -style: Unsuitable

I cut my code and make the following example:
1.h:
`static int NSSet;`

command:
clang-format -i "-style={BasedOnStyle: Webkit, Language: Cpp}" ./1.h
To temporarily avoid this, I change the command to the following, and it works.
clang-format -i "-style={BasedOnStyle: Webkit}" ./1.h

I lookup the llvm code and guess it's the following code error:
https://github.com/llvm/llvm-project/blame/main/clang/lib/Format/Format.cpp
guessIsObjC
It sounds clang-format guess it's objc file.

clang version:
clang-format version 14.0.6

suggestion:
for .h file, clang-format try to guess if it's objc file.
I think we can let the coder select if we should need this guess.
For me, I don't use objc anyway, it's better to disable objc suggest for me.

</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJylVMFuozAQ_Rq4jIIIBEgOHJpmI0VabQ_d1Z4NDODGYGSbpvz9jg1pk6p7WK0UGdsz8-bNzHMKWU35CUaNUArWN6taqo4ZMBIGpui2m6AcBi86tsgqVFBzgcD6CjpEcmsRaimEvPC-AVRKKi9-8MKDFz58syeHYm0rbSaBZIRfvR65YQWdnN-8nqAcjcsmqyUBO-PnBG-sGxzKHLQO2ve9l4baMMNL4L2BH8_PaLx4T7e3WUrZdYT9HnRX84qDF0VXogcv2--Zxuqpf75S_43FmRsveoTvFDeyxt0-Un-yA4VCQH2ynBz2TwkGu0EqpriYgL1KXlE9XNt4KrcliLnAhZVt-l291tHecwMXqc46-B_SXzC8dl5IeR4Hl1uI1-5jBM2IWoOtONOfRuF87gfeGjNoe4qO9Gu4accioNroYGGXz2pQ8gVLwjwWgnVI347xnj6uLuvFC1qPrr73TWBV6NI4Uif9VLw8LgUY0HLsK30v4TvysngpnXaDOzlYf3hFkqjsvxbFYoT1JgiD9DZYj02D2txGUgwErctjZ3f_otRkB7ywqv9G7GQl0p_hQrJgPYjlkdl2K9AoqHM2msy6laOooEecZTVDLzDUNOhwVlpFDKPMuEfu0rF-urDJGhcSBRpD8ESv4tq-zNlvqRBqB7Yg-5iv03SzSeI4S_0qj6tdvGO-4UZgPjd0qfj2H-NmaLNq_FGJ_J8Vw7UmINok2zBJ_DYvWMSqJEk34S7b1kW22WY7VtYxsgyrdJ36ghUodO4ley85-DyPwigKd9FuTWucBHWxZklYVBQVbqMIvU2IJEcR2MSBVI2vcsehGBtNRsG10R9GpjVvaAJXfDaaVqr8jTM5jSreZL5jnDu6fwBjPcAU">