Use VS 2017 and 2019 on CI, fix cast issue in dart_idl (#5740)
* vs2019 * another attempt * syntax * fewer * fix dart
This commit is contained in:
parent
316d7c2089
commit
f2a1272303
23
appveyor.yml
23
appveyor.yml
|
@ -2,8 +2,6 @@ branches:
|
|||
only:
|
||||
- master
|
||||
|
||||
os: Visual Studio 2015
|
||||
|
||||
environment:
|
||||
|
||||
global:
|
||||
|
@ -14,15 +12,26 @@ environment:
|
|||
CPP_TEST_OPTIONS: ""
|
||||
|
||||
matrix:
|
||||
- CMAKE_VS_VERSION: "10 2010"
|
||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
|
||||
CMAKE_VS_VERSION: "10 2010"
|
||||
CMAKE_OPTIONS: "-DFLATBUFFERS_BUILD_LEGACY=1"
|
||||
CPP_TEST_OPTIONS: "--std-cpp c++0x"
|
||||
MONSTER_EXTRA: "skip"
|
||||
|
||||
- CMAKE_VS_VERSION: "12 2013"
|
||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
|
||||
CMAKE_VS_VERSION: "12 2013"
|
||||
MONSTER_EXTRA: "skip"
|
||||
|
||||
- CMAKE_VS_VERSION: "14 2015"
|
||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015
|
||||
CMAKE_VS_VERSION: "14 2015"
|
||||
MONSTER_EXTRA: ""
|
||||
|
||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
|
||||
CMAKE_VS_VERSION: "15 2017"
|
||||
MONSTER_EXTRA: ""
|
||||
|
||||
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2019
|
||||
CMAKE_VS_VERSION: "16 2019"
|
||||
MONSTER_EXTRA: ""
|
||||
|
||||
platform:
|
||||
|
@ -37,7 +46,9 @@ before_build:
|
|||
- set MONSTER_EXTRA=%MONSTER_EXTRA%
|
||||
- cmake . -G"Visual Studio %CMAKE_VS_VERSION%" -DFLATBUFFERS_CODE_SANITIZE=1 %CMAKE_OPTIONS%
|
||||
# This cuts down on a lot of noise generated by xamarin warnings.
|
||||
- del "C:\Program Files (x86)\MSBuild\14.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets"
|
||||
- if exist "C:\Program Files (x86)\MSBuild\14.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets" del "C:\Program Files (x86)\MSBuild\14.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets"
|
||||
- if exist "C:\Program Files (x86)\MSBuild\15.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets" del "C:\Program Files (x86)\MSBuild\15.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets"
|
||||
- if exist "C:\Program Files (x86)\MSBuild\16.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets" del "C:\Program Files (x86)\MSBuild\16.0\Microsoft.Common.targets\ImportAfter\Xamarin.Common.targets"
|
||||
|
||||
build:
|
||||
project: ALL_BUILD.vcxproj
|
||||
|
|
|
@ -454,7 +454,7 @@ class DartGenerator : public BaseGenerator {
|
|||
it != struct_def.fields.vec.end(); ++it) {
|
||||
auto &field = **it;
|
||||
if (field.deprecated) continue;
|
||||
auto offset = it - struct_def.fields.vec.begin();
|
||||
auto offset = static_cast<int>(it - struct_def.fields.vec.begin());
|
||||
non_deprecated_fields.push_back(std::make_pair(offset, &field));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue