profile
viewpoint

Ask questionsdifferent behavior by json_parser.Parse<0>(str) for doubles

Here is the config file used by the RAPID JASON

{
    "config_version": 2,  
    "determinism_flag": 1,  
    "solver": {
        "print_grid_stats": 1,  
        "algorithm": "AGGREGATION", 
        "obtain_timings": 1,  
        "solver": "AMG", 
        "smoother": "BLOCK_JACOBI", 
        "print_solve_stats": 1,  
        "presweeps": 2,  
        "selector": "SIZE_2", 
        "convergence": "RELATIVE_MAX_CORE", 
        "coarsest_sweeps": 2,  
        "max_iters": 2,  
        "monitor_residual": 1,  
        "min_coarse_rows": 2,  
        "relaxation_factor": 0.75, 
        "scope": "main", 
        "max_levels": 1000, 
        "postsweeps": 2,  
        "tolerance": 1e-10, 
        "norm": "L2", 
        "use_scalar_norm": 1,
        "cycle": "V",
         "store_res_history": 1,
        "solver_verbose" : 1 
    }   
}

The json_parser.Parse<0>(str) for a unit test reads everything correctly but when connected to another bigger project Doubles are read wrong. here is the entire output. I appreciate any feedback on this issue., Thanks in advance.

determinism_flag value 1 solver value AMG print_grid_stats value 1 algorithm value AGGREGATION obtain_timings value 1 smoother value BLOCK_JACOBI print_solve_stats value 1 presweeps value 2 selector value SIZE_8 convergence value RELATIVE_MAX_CORE coarsest_sweeps value 2 max_iters value 1 monitor_residual value 1 min_coarse_rows value 2 relaxation_factor value 7.5e+307 max_levels value 1000 postsweeps value 2 tolerance value 1e+303

SIDE NOTE: SIMD is turned off for both cases

Tencent/rapidjson

Answer questions miloyip

Will it be possible the "bigger project" also include another version of rapidjson, so that the linker behave incorrectly? If so, you may try customizing the namespace of your part by defining RAPIDJSON_NAMESPACE to an unique identifier.

useful!

Related questions

是否支持流式解析以及多个json分离解析 hot 1
是否支持流式解析以及多个json分离解析 hot 1
RapidJSON causes cc1plus: internal compiler error: Segmentation fault - rapidjson hot 1
GenericMemberIterator::Iterator implicitly declared private when RAPIDJSON_NOMEMBERITERATORCLASS is defined hot 1
Always gets a core dump while creating json string (rapidjson) hot 1
Bazel Support hot 1
Syntax typo in tutorial hot 1
是否支持流式解析以及多个json分离解析 hot 1
作者你好,我 想请教一下,这个框架是否能够将变量中文stirng 转成wchar_t? 在文档只看到定量 hot 1
travis on windows hot 1
Added headers to my project and got thousands of errors hot 1
Added headers to my project and got thousands of errors hot 1
想要的反斜杠 \. 无法表示,否则JSON解析出错 hot 1
Assertion `stack_.GetSize() == sizeof(ValueType)' failed hot 1
source:https://uonfu.com/
Github User Rank List