[Issue 22070] New: importC: Error: string literal is not an lvalue

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Jun 22 19:31:54 UTC 2021


https://issues.dlang.org/show_bug.cgi?id=22070

          Issue ID: 22070
           Summary: importC: Error: string literal is not an lvalue
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: major
          Priority: P1
         Component: dmd
          Assignee: nobody at puremagic.com
          Reporter: ibuclaw at gdcproject.org

It is an lvalue in C
"""
6.5.1-4: A string literal is a primary expression.  It is an lvalue with type
as detailed in 6.4.5.
"""

Reduced test
---
char(*var)[4] = &"123";

--


More information about the Digitalmars-d-bugs mailing list