BrettMayson / HEMTT

Build System for Arma 3
https://brettmayson.github.io/HEMTT
GNU General Public License v2.0
109 stars 40 forks source link

Pre-processor comment slash error with include #276

Closed jonpas closed 4 years ago

jonpas commented 4 years ago

HEMTT Version: 0.7.3-897d451-debug Project: https://github.com/CBATeam/CBA_A3/commit/b4455943d8fb83eed7cc8a4c696bad2a7987f559

Description:

Pre-processor fails when slash / is used in a comment which is in the same line as #include pre-processor instruction. If comment is on it's own line all works ok.

Steps to reproduce:

Additional information:

Works fine with #define and other pre-processor instructions. Also works fine with some other text. Pre-processor might possibly be trying to calculate a math expression?

HEMTT Output:

[jonpas@loki] $ ./hemttdev build jam                                                                                                          (hemtt) ~/Data/Work/Arma 3/Mods/CBA_A3
HEMTT 0.7.3-897d451-debug
Environment: dev

warning: .gitignore is missing recommended value `keys/*`
warning: .gitignore is missing recommended value `.hemtt`
warning: deprecated value `sig_name` in `hemtt.toml` - use `authority`
warning: Unable to locate binarize.exe
    Files will be packed as is
♻️ Clean          [00:00:00] [##############################] [1|1]
🔍 Checks         [00:00:00] [##############################] [1|1]
🚧 Prebuild       [00:00:00] [##############################] [1|1]
error: Unable to preprocess `CfgMagazineWells.hpp`
    Preprocessor Parse: class CfgMagazineWells {

<snip>

    #include "magwells_357SIG.hpp"                  
    #include "magwells_380ACP.hpp"                  
    #include "magwells_38Spec.hpp" 
    #include "magwells_38_200.hpp"                  // .38/200 | 9x20mmR
    #include "magwells_40SW.hpp"    

<snip>

error: Unable to build `addons/jam`

Comment with slash is left, others are correctly removed.

jonpas commented 4 years ago

Last blocker for current CBA use, ref.: https://github.com/CBATeam/CBA_A3/pull/1145 (also test branch)

BrettMayson commented 4 years ago

closed with 477e44c5ef807f1a4ba903ce00adb7682f132d49