www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 22034] New: std.ascii can't be used with -betterc


          Issue ID: 22034
           Summary: std.ascii can't be used with -betterc
           Product: D
           Version: D2
          Hardware: x86_64
                OS: All
            Status: NEW
          Severity: critical
          Priority: P1
         Component: phobos
          Assignee: nobody puremagic.com
          Reporter: bitworld qq.com

Here is a simple code for test:

import std.ascii : isLower;

extern(C) void main()
    bool r = isLower('A');

To run:
dmd app.d -betterC

The error message:

app.o: In function `main':
source/app.d:(.text.main[main]+0xa): undefined reference to
collect2: error: ld returned 1 exit status
Error: linker exited with status 1

The compiler is DMD v2.097.0.

Jun 18 2021