Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion eng/native/configurecompiler.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ include(${CMAKE_CURRENT_LIST_DIR}/configuretools.cmake)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
set(CMAKE_C_STANDARD 11)
set(CMAKE_C_STANDARD_REQUIRED ON)
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

# We need to set this to Release as there's no way to intercept configuration-specific linker flags
Expand Down
2 changes: 1 addition & 1 deletion src/coreclr/ilasm/assem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1521,7 +1521,7 @@ unsigned hash(
unsigned length, /* the length of the key */
unsigned initval) /* the previous hash, or an arbitrary value */
{
register unsigned a,b,c,len;
unsigned a,b,c,len;

/* Set up the internal state */
len = length;
Expand Down
11 changes: 11 additions & 0 deletions src/coreclr/nativeaot/Bootstrap/stdcppshim.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ namespace std
{
struct nothrow_t {};
extern const nothrow_t nothrow = {};
using size_t = ::size_t;
}

void* operator new(size_t n, const std::nothrow_t&) noexcept
Expand All @@ -28,3 +29,13 @@ void operator delete[](void *p) noexcept
{
free(p);
}

void operator delete(void* p, std::size_t) noexcept
{
free(p);
}

void operator delete[](void* p, std::size_t) noexcept
{
free(p);
}
3 changes: 2 additions & 1 deletion src/coreclr/pal/src/include/pal/list.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,13 @@ Revision History:
#ifndef _LIST_H_INCLUDED
#define _LIST_H_INCLUDED

#include <cstddef>

#ifdef __cplusplus
extern "C"
{
#endif // __cplusplus

#include <cstddef>

typedef struct _LIST_ENTRY {
struct _LIST_ENTRY *Flink;
Expand Down
9 changes: 8 additions & 1 deletion src/coreclr/vm/threads.h
Original file line number Diff line number Diff line change
Expand Up @@ -5156,17 +5156,24 @@ class CoopTransitionHolder
{
Frame * m_pFrame;

#ifdef DEBUG
int m_uncaughtExceptions;
#endif

public:
CoopTransitionHolder(Thread * pThread)
: m_pFrame(pThread->m_pFrame)
{
LIMITED_METHOD_CONTRACT;
#ifdef DEBUG
m_uncaughtExceptions = std::uncaught_exceptions();
#endif
}

~CoopTransitionHolder()
{
WRAPPER_NO_CONTRACT;
_ASSERTE_MSG(m_pFrame == nullptr || std::uncaught_exception(), "Early return from JIT/EE interface method");
_ASSERTE_MSG(m_pFrame == nullptr || m_uncaughtExceptions < std::uncaught_exceptions(), "Early return from JIT/EE interface method");
if (m_pFrame != nullptr)
COMPlusCooperativeTransitionHandler(m_pFrame);
}
Expand Down
2 changes: 2 additions & 0 deletions src/native/corehost/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,8 @@ add_library(fxr_resolver INTERFACE)
target_sources(fxr_resolver INTERFACE fxr_resolver.cpp)
target_include_directories(fxr_resolver INTERFACE fxr)

add_compile_definitions(RAPIDJSON_HAS_CXX17)

if ((NOT DEFINED CLR_CMAKE_USE_SYSTEM_RAPIDJSON) OR (NOT CLR_CMAKE_USE_SYSTEM_RAPIDJSON))
include_directories(${CLR_SRC_NATIVE_DIR}/external/)
endif()
Expand Down
2 changes: 2 additions & 0 deletions src/native/corehost/apphost/static/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ add_subdirectory(../../hostmisc hostmisc)
configure_file(${CLR_SRC_NATIVE_DIR}/corehost/configure.h.in ${GENERATED_INCLUDE_DIR}/corehost/configure.h)
target_include_directories(hostmisc_interface INTERFACE ${GENERATED_INCLUDE_DIR}/corehost)

add_compile_definitions(RAPIDJSON_HAS_CXX17)

if ((NOT DEFINED CLR_CMAKE_USE_SYSTEM_RAPIDJSON) OR (NOT CLR_CMAKE_USE_SYSTEM_RAPIDJSON))
include_directories(${CLR_SRC_NATIVE_DIR}/external/)
endif()
Expand Down
Loading