jmdavis / dxml

An XML parsing library written in D.
Boost Software License 1.0
32 stars 10 forks source link

decodeXML does not compile when given a range of type char[] #23

Closed BitterlyIronic closed 4 years ago

BitterlyIronic commented 4 years ago
import std.stdio: writeln;
import dxml.util;

char[] str;

str ~= "hello";

str.decodeXML.writeln;

The above code fails to compile with Error: cannot implicitly convert expression range of type char[] to string. Tested with DMD 2.090.1 on Windows.

wchar[], dchar[], string, wstring, and dstring all work as expected.

jmdavis commented 4 years ago

It looks like adding char[] to the list of types tested triggers several bugs - in this particular case due to code that's specific to arrays of char only having been tested with string. So, I'll need to work my way through them.

jmdavis commented 4 years ago

Sorry for the delay. 0.4.2 should fix the problem.