<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="font-size:12pt">Good point - another similar example would be the syntax highlight</span></div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span style="font-size:12pt">in the IDEs</span> or editors that frequently use the file extensions too.<br>
<span style="font-size:12pt"></span>
<div></div>
<span style="font-family:Calibri,Arial,Helvetica,sans-serif;font-size:12pt;color:rgb(0,0,0)"></span><br>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="divRplyFwdMsg" dir="ltr"><font style="font-size:11pt" face="Calibri, sans-serif" color="#000000"><b>From:</b> cfe-dev <cfe-dev-bounces@lists.llvm.org> on behalf of Stephen Kelly via cfe-dev <cfe-dev@lists.llvm.org><br>
<b>Sent:</b> 17 February 2021 22:12<br>
<b>To:</b> cfe-dev@lists.llvm.org <cfe-dev@lists.llvm.org><br>
<b>Subject:</b> Re: [cfe-dev] [RFC] New file extension for compiling C++ for OpenCL sources</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt">
<div class="PlainText"><br>
On 17/02/2021 16:36, Arthur O'Dwyer via cfe-dev wrote:<br>
> FWIW, as a complete outsider, as a complete non-user of OpenCL (but a <br>
> heavy user of C++), I don't see why a new filename extension is a good <br>
> thing. <br>
<br>
<br>
I'm also an opencl outsider.<br>
<br>
However, if opencl files are to be detected by a buildsystem like (but <br>
not limited to) cmake, then a file extension is a good thing. Consider <br>
this cmake code:<br>
<br>
cmake_minimum_required(VERSION 3.10)<br>
<br>
project(testproj C CXX OBJCXX OBJC)<br>
<br>
add_library(test<br>
     test.cpp<br>
     test.c<br>
     test.m<br>
     test.mm<br>
)<br>
<br>
<br>
CMake detects the source-language of each source file and uses the <br>
appropriate driver and language compile option for each one.<br>
<br>
With a file extension for opencl, CMake could use the appropriate <br>
driver/option for that language too. Without a distinct file extension <br>
for it, the user would have to tell cmake what the language is, which is <br>
inconvenient for the user.<br>
<br>
Thanks,<br>
<br>
Stephen.<br>
<br>
<br>
_______________________________________________<br>
cfe-dev mailing list<br>
cfe-dev@lists.llvm.org<br>
<a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev">https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev</a><br>
</div>
</span></font></div>
</body>
</html>