diff options
author | Jan Vorlicek <janvorli@microsoft.com> | 2015-03-25 18:14:11 +0100 |
---|---|---|
committer | Jan Vorlicek <janvorli@microsoft.com> | 2015-03-26 00:27:51 +0100 |
commit | 32c2a3bc5a6b0afe26812b5bf255f43790ef979d (patch) | |
tree | 2d591e6a79c082c610e0d4c8c5d10491808fd7c8 /src/jit/unwindamd64.cpp | |
parent | 04aed1266c4419667b1348426ce59f843449cfdb (diff) | |
download | coreclr-32c2a3bc5a6b0afe26812b5bf255f43790ef979d.tar.gz coreclr-32c2a3bc5a6b0afe26812b5bf255f43790ef979d.tar.bz2 coreclr-32c2a3bc5a6b0afe26812b5bf255f43790ef979d.zip |
Fix warnings in the jitter code
This change fixes some of the warnings in the jitter code on Linux. With this change
combined with an upcoming change in the rest of the codebase, 16 warning disabling
options can be removed.
The issues in the jitter were:
1) Incorrect typedefs for const_reference and const_pointer (the const was ignored)
2) Member initiazalization order in class constructor didn't correspond to the member order in some classes
3) Objects with vtables were copied via memcpy. While this is intentional, cast of the pointers to void*
is required to silence clang warning
4) Comparing values of different enums - there are cases of two enums containing the same values.
5) Casting int to pointer - the cast was legal (forming a handle), adding cast to size_t in between used to fix the warning
6) "static struct" - removed the static keyword
7) Missing return value in methods with _ASSERTE
8) Class name classifier on methods in the .h
9) Specialized template member functions need to be defined out of the class
Diffstat (limited to 'src/jit/unwindamd64.cpp')
-rw-r--r-- | src/jit/unwindamd64.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/jit/unwindamd64.cpp b/src/jit/unwindamd64.cpp index 644d8749d7..b93c15d223 100644 --- a/src/jit/unwindamd64.cpp +++ b/src/jit/unwindamd64.cpp @@ -636,9 +636,9 @@ void Compiler::unwindEmitFuncHelper(FuncInfoDsc* func, void* pHotCode, void* pCo void Compiler::unwindEmitFunc(FuncInfoDsc* func, void* pHotCode, void* pColdCode) { // Verify that the JIT enum is in sync with the JIT-EE interface enum - static_assert_no_msg(FUNC_ROOT == CORJIT_FUNC_ROOT); - static_assert_no_msg(FUNC_HANDLER == CORJIT_FUNC_HANDLER); - static_assert_no_msg(FUNC_FILTER == CORJIT_FUNC_FILTER); + static_assert_no_msg(FUNC_ROOT == (FuncKind)CORJIT_FUNC_ROOT); + static_assert_no_msg(FUNC_HANDLER == (FuncKind)CORJIT_FUNC_HANDLER); + static_assert_no_msg(FUNC_FILTER == (FuncKind)CORJIT_FUNC_FILTER); unwindEmitFuncHelper(func, pHotCode, pColdCode, true); |