digitalmars.D.learn - How to fix wrong deprecation message - dmd-2.075.1
- apz28 (13/13) Aug 15 2017 void main()
- Daniel Kozak via Digitalmars-d-learn (10/20) Aug 15 2017 You should open an issue on https://issues.dlang.org/
- Steven Schveighoffer (3/16) Aug 16 2017 Help me out, what is the problem with the message?
- Daniel Kozak via Digitalmars-d-learn (8/25) Aug 16 2017 It should not be print? AIAIK std.utf.toUTF16 is not deprecated:
- Steven Schveighoffer (6/16) Aug 16 2017 Hm.. that's a bug in the compiler. Only one is marked, but both are
- Pham (3/19) Aug 16 2017 Issue 17757 is created
- Johan Engelen (5/21) Aug 16 2017 I ran into this too the other day, and found that the issue was
void main() { import std.utf : toUTF16; // Same problem with toUTF8 wstring s = toUTF16!string("abc"); } Compilation output: /d500/f513.d(3): Deprecation: function std.utf.toUTF16 is deprecated - To be removed November 2017. Please use std.utf.encode instead. /d500/f513.d(3): Deprecation: function std.utf.toUTF16 is deprecated - To be removed November 2017. Please use std.utf.encode instead.
Aug 15 2017
You should open an issue on https://issues.dlang.org/ until it is fixed you can use lazy variation byChar, byWchar or byUTF: void main() { import std.utf : byWchar; import std.array : array; wstring s = byWchar("abc").array; } On Wed, Aug 16, 2017 at 7:09 AM, apz28 via Digitalmars-d-learn < digitalmars-d-learn puremagic.com> wrote:void main() { import std.utf : toUTF16; // Same problem with toUTF8 wstring s = toUTF16!string("abc"); } Compilation output: /d500/f513.d(3): Deprecation: function std.utf.toUTF16 is deprecated - To be removed November 2017. Please use std.utf.encode instead. /d500/f513.d(3): Deprecation: function std.utf.toUTF16 is deprecated - To be removed November 2017. Please use std.utf.encode instead.
Aug 15 2017
On 8/16/17 1:09 AM, apz28 wrote:void main() { import std.utf : toUTF16; // Same problem with toUTF8 wstring s = toUTF16!string("abc"); } Compilation output: /d500/f513.d(3): Deprecation: function std.utf.toUTF16 is deprecated - To be removed November 2017. Please use std.utf.encode instead. /d500/f513.d(3): Deprecation: function std.utf.toUTF16 is deprecated - To be removed November 2017. Please use std.utf.encode instead.Help me out, what is the problem with the message? -Steve
Aug 16 2017
It should not be print? AIAIK std.utf.toUTF16 is not deprecated: http://dlang.org/phobos/std_utf.html#toUTF16 OK this one is:https://github.com/dlang/phobos/blob/v2.075.1/std/utf.d#L2760 (but this one is not in doc) but this one should not be deprecated: https://github.com/dlang/phobos/blob/v2.075.1/std/utf.d#L2777 On Wed, Aug 16, 2017 at 3:02 PM, Steven Schveighoffer via Digitalmars-d-learn <digitalmars-d-learn puremagic.com> wrote:On 8/16/17 1:09 AM, apz28 wrote:void main() { import std.utf : toUTF16; // Same problem with toUTF8 wstring s = toUTF16!string("abc"); } Compilation output: /d500/f513.d(3): Deprecation: function std.utf.toUTF16 is deprecated - To be removed November 2017. Please use std.utf.encode instead. /d500/f513.d(3): Deprecation: function std.utf.toUTF16 is deprecated - To be removed November 2017. Please use std.utf.encode instead.Help me out, what is the problem with the message? -Steve
Aug 16 2017
On 8/16/17 9:12 AM, Daniel Kozak via Digitalmars-d-learn wrote:It should not be print? AIAIK std.utf.toUTF16 is not deprecated: http://dlang.org/phobos/std_utf.html#toUTF16 OK this one is:https://github.com/dlang/phobos/blob/v2.075.1/std/utf.d#L2760 (but this one is not in doc) but this one should not be deprecated: https://github.com/dlang/phobos/blob/v2.075.1/std/utf.d#L2777Hm.. that's a bug in the compiler. Only one is marked, but both are treated as deprecated. I'm wondering if just resolving the overload triggers the message. Please file an issue. -Steve
Aug 16 2017
On Wednesday, 16 August 2017 at 13:55:31 UTC, Steven Schveighoffer wrote:On 8/16/17 9:12 AM, Daniel Kozak via Digitalmars-d-learn wrote:Issue 17757 is createdIt should not be print? AIAIK std.utf.toUTF16 is not deprecated: http://dlang.org/phobos/std_utf.html#toUTF16 OK this one is:https://github.com/dlang/phobos/blob/v2.075.1/std/utf.d#L2760 (but this one is not in doc) but this one should not be deprecated: https://github.com/dlang/phobos/blob/v2.075.1/std/utf.d#L2777Hm.. that's a bug in the compiler. Only one is marked, but both are treated as deprecated. I'm wondering if just resolving the overload triggers the message. Please file an issue. -Steve
Aug 16 2017
On Wednesday, 16 August 2017 at 16:54:04 UTC, Pham wrote:On Wednesday, 16 August 2017 at 13:55:31 UTC, Steven Schveighoffer wrote:I ran into this too the other day, and found that the issue was already filed: https://issues.dlang.org/show_bug.cgi?id=17193 - JohanOn 8/16/17 9:12 AM, Daniel Kozak via Digitalmars-d-learn wrote:Issue 17757 is createdIt should not be print? AIAIK std.utf.toUTF16 is not deprecated: http://dlang.org/phobos/std_utf.html#toUTF16 OK this one is:https://github.com/dlang/phobos/blob/v2.075.1/std/utf.d#L2760 (but this one is not in doc) but this one should not be deprecated: https://github.com/dlang/phobos/blob/v2.075.1/std/utf.d#L2777Hm.. that's a bug in the compiler. Only one is marked, but both are treated as deprecated.
Aug 16 2017