From b8cfaeb3f43c52f82b4464cd4c937c5072b62ef2 Mon Sep 17 00:00:00 2001 From: youben11 Date: Tue, 18 Jan 2022 13:02:57 +0100 Subject: [PATCH] fix: ignore narrowing errors on Mac --- compiler/CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/compiler/CMakeLists.txt b/compiler/CMakeLists.txt index 5102be320..a4d794b96 100644 --- a/compiler/CMakeLists.txt +++ b/compiler/CMakeLists.txt @@ -7,6 +7,10 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin) set(CMAKE_CXX_STANDARD 14) set(CMAKE_EXPORT_COMPILE_COMMANDS ON) +# Wouldn't be able to compile LLVM without this on Mac (using either Clang or AppleClang) +if (APPLE) + add_definitions("-Wno-narrowing") +endif() # If we are trying to build the compiler with LLVM/MLIR as libraries if( NOT DEFINED LLVM_EXTERNAL_CONCRETELANG_SOURCE_DIR )