• Stephan Bergmann's avatar
    Avoid clang-cl -Werror,-Wbitfield-constant-conversion · 06e32106
    Stephan Bergmann yazdı
    ...when (non-negative) QueryOp enumerators LESS/GREATER_EQUAL are crammed into
    a 2-bit meOp bitfield, where enums are implictly signed for MSVC, so the values
    actually storable in the bitfield range from -2 to +1.
    
    The clang-cl warning would go away when fixing the underlying type of QueryOp as
    unsigned, but then GCC would start to emit "error:
    ‘ScLookupCache::QueryCriteria::meOp’ is too small to hold all values of ‘enum
    ScLookupCache::QueryOp’ [-Werror]."
    
    So don't bother with bitfields at all:  For QueryCritera, for one there's a
    union member with a double and a pointer, so sizeof (QueryCriteria) will be
    twice the size of double anyway; and for another, MSVC doesn't combine bitfields
    of different type, so the bool members were separated from meOp anyway.  For
    QueryKey the reason for a bitfield is even less clear cut, and it might only
    have been there so that comparing (negative!) values read out of
    QueryCritera::meOp compare equal to values read out of QueryKey::meOp under
    MSVC.
    
    Change-Id: I69fb068bea914c00a29001155218cb9f1b8f8a9a
    06e32106
Adı
Son kayıt (commit)
Son güncelleme
..
inc Loading commit data...
qa Loading commit data...
sdi Loading commit data...
source Loading commit data...
uiconfig/scalc Loading commit data...
util Loading commit data...
workben Loading commit data...
AllLangResTarget_sc.mk Loading commit data...
CppunitTest_sc_annotationobj.mk Loading commit data...
CppunitTest_sc_annotationshapeobj.mk Loading commit data...
CppunitTest_sc_annotationsobj.mk Loading commit data...
CppunitTest_sc_bugfix_test.mk Loading commit data...
CppunitTest_sc_cellrangeobj.mk Loading commit data...
CppunitTest_sc_chart_regression_test.mk Loading commit data...
CppunitTest_sc_condformats.mk Loading commit data...
CppunitTest_sc_copypaste.mk Loading commit data...
CppunitTest_sc_core.mk Loading commit data...
CppunitTest_sc_databaserangeobj.mk Loading commit data...
CppunitTest_sc_datapilotfieldobj.mk Loading commit data...
CppunitTest_sc_datapilottableobj.mk Loading commit data...
CppunitTest_sc_editfieldobj_cell.mk Loading commit data...
CppunitTest_sc_editfieldobj_header.mk Loading commit data...
CppunitTest_sc_filters_test.mk Loading commit data...
CppunitTest_sc_html_export_test.mk Loading commit data...
CppunitTest_sc_macros_test.mk Loading commit data...
CppunitTest_sc_modelobj.mk Loading commit data...
CppunitTest_sc_namedrangeobj.mk Loading commit data...
CppunitTest_sc_namedrangesobj.mk Loading commit data...
CppunitTest_sc_new_cond_format_api.mk Loading commit data...
CppunitTest_sc_opencl_test.mk Loading commit data...
CppunitTest_sc_outlineobj.mk Loading commit data...
CppunitTest_sc_perfobj.mk Loading commit data...
CppunitTest_sc_rangelst_test.mk Loading commit data...
CppunitTest_sc_recordchanges.mk Loading commit data...
CppunitTest_sc_styleloaderobj.mk Loading commit data...
CppunitTest_sc_subsequent_export_test.mk Loading commit data...
CppunitTest_sc_subsequent_filters_test.mk Loading commit data...
CppunitTest_sc_tablesheetobj.mk Loading commit data...
CppunitTest_sc_tablesheetsobj.mk Loading commit data...
CppunitTest_sc_ucalc.mk Loading commit data...
CustomTarget_uiconfig.mk Loading commit data...
JunitTest_sc_complex.mk Loading commit data...
JunitTest_sc_unoapi_1.mk Loading commit data...
JunitTest_sc_unoapi_2.mk Loading commit data...
JunitTest_sc_unoapi_3.mk Loading commit data...
JunitTest_sc_unoapi_4.mk Loading commit data...
JunitTest_sc_unoapi_5.mk Loading commit data...
JunitTest_sc_unoapi_6.mk Loading commit data...
JunitTest_sc_unoapi_7.mk Loading commit data...
Library_sc.mk Loading commit data...
Library_scd.mk Loading commit data...
Library_scfilt.mk Loading commit data...
Library_scqahelper.mk Loading commit data...
Library_scui.mk Loading commit data...
Library_vbaobj.mk Loading commit data...
Makefile Loading commit data...
Module_sc.mk Loading commit data...
README Loading commit data...
UIConfig_scalc.mk Loading commit data...