[LLVMbugs] [Bug 21935] New: error: cannot initialize a variable of type 'char *' with an rvalue of type 'const char *'
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Tue Dec 16 22:06:03 PST 2014
http://llvm.org/bugs/show_bug.cgi?id=21935
Bug ID: 21935
Summary: error: cannot initialize a variable of type 'char *'
with an rvalue of type 'const char *'
Product: clang
Version: trunk
Hardware: PC
OS: Windows NT
Status: NEW
Severity: normal
Priority: P
Component: -New Bugs
Assignee: unassignedclangbugs at nondot.org
Reporter: aamen521 at 163.com
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
Created attachment 13553
--> http://llvm.org/bugs/attachment.cgi?id=13553&action=edit
testcpp
int main()
{
bool mbool = false;
char *p = mbool?"ssss":"faffafa";
return 0;
}
testchar.cpp:4:8: error: cannot initialize a variable of type 'char *' with an
rvalue of type 'const char *'
char *p = mbool?"ssss":"faffafa";
^ ~~~~~~~~~~~~~~~~~~~~~~
1 error generated.
CL.exe can compile this
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20141217/e13f38bd/attachment.html>
More information about the llvm-bugs
mailing list