Bug 22763 – importing std.utf fails in BetterC

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
druntime
Product
D
Version
D2
Platform
All
OS
All
Creation time
2022-02-11T17:28:55Z
Last change time
2022-04-20T18:07:55Z
Keywords
pull
Assigned to
No Owner
Creator
Paul Backus

Comments

Comment #0 by snarwin+bugzilla — 2022-02-11T17:28:55Z
As of DMD 2.098.1, the following program fails to compile with -betterC --- import std.utf; --- The error message is: --- /dlang/dmd/linux/bin64/../../src/phobos/std/utf.d(66): Error: module `core.exception` import `UnicodeException` not found --- This error occurs because the druntime symbol core.exception.UnicodeException is in the `else` block of a `version (D_BetterC)` declaration.
Comment #1 by dlang-bot — 2022-04-20T16:51:43Z
@pbackus created dlang/druntime pull request #3804 "Fix issue 22763 - importing std.utf fails in BetterC" fixing this issue: - Fix issue 22763 - importing std.utf fails in BetterC BetterC-compatible code should be allowed to import the symbols in this module, as long as it does not attempt to use them at runtime when compiled in BetterC mode. https://github.com/dlang/druntime/pull/3804
Comment #2 by dlang-bot — 2022-04-20T18:07:55Z
dlang/druntime pull request #3804 "Fix issue 22763 - importing std.utf fails in BetterC" was merged into master: - af90c52a512044089b2e253124a49a821c02939c by Paul Backus: Fix issue 22763 - importing std.utf fails in BetterC BetterC-compatible code should be allowed to import the symbols in this module, as long as it does not attempt to use them at runtime when compiled in BetterC mode. https://github.com/dlang/druntime/pull/3804