aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/sdp/ao_read_source_files.d
diff options
context:
space:
mode:
authorRalph Amissah <ralph@amissah.com>2017-01-12 20:51:12 -0500
committerRalph Amissah <ralph@amissah.com>2019-04-10 15:14:14 -0400
commit45e1b786144b8ef0a70a235f8a1a89e90a752d8f (patch)
treee4e9d787fe9f0bce330a8db407e949aa9bf5ee8e /src/sdp/ao_read_source_files.d
parentdom structure, levels marked up & collapsed (use e.g. in epub toc) (diff)
0.11.0 improved message passing, using templates
Diffstat (limited to 'src/sdp/ao_read_source_files.d')
-rw-r--r--src/sdp/ao_read_source_files.d11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/sdp/ao_read_source_files.d b/src/sdp/ao_read_source_files.d
index 5ff0ec1..a2bf75d 100644
--- a/src/sdp/ao_read_source_files.d
+++ b/src/sdp/ao_read_source_files.d
@@ -43,7 +43,7 @@ template SiSUmarkupRaw() {
private
struct MarkupRawUnit {
private import std.file;
- final private string readInMarkupSource(in string fn_src) {
+ final private string readInMarkupSource(in char[] fn_src) {
enforce(
exists(fn_src)!=0,
"file not found"
@@ -102,7 +102,10 @@ template SiSUmarkupRaw() {
);
return t;
}
- final char[][] getInsertMarkupSourceContentRawLineArray(in string fn_src, Regex!(char) rgx_file) {
+ final char[][] getInsertMarkupSourceContentRawLineArray(
+ in char[] fn_src,
+ Regex!(char) rgx_file
+ ) {
enforce(
match(fn_src, rgx_file),
"not a sisu markup filename"
@@ -166,7 +169,7 @@ template SiSUmarkupRaw() {
auto insert_fn = m.captures[2];
auto insert_sub_pth = m.captures[1];
auto fn_src_insert =
- to!string(markup_src_file_path ~ insert_sub_pth ~ insert_fn);
+ chainPath(markup_src_file_path, insert_sub_pth ~ insert_fn).array;
auto raw = MarkupRawUnit();
auto markup_sourcesubfile_insert_content =
raw.getInsertMarkupSourceContentRawLineArray(fn_src_insert, rgx.src_fn_find_inserts);
@@ -227,7 +230,7 @@ template SiSUmarkupRaw() {
auto insert_fn = m.captures[2];
auto insert_sub_pth = m.captures[1];
auto fn_src_insert =
- to!string(markup_src_file_path ~ insert_sub_pth ~ insert_fn);
+ chainPath(markup_src_file_path, insert_sub_pth ~ insert_fn).array;
auto raw = MarkupRawUnit();
/+ TODO +/
if (auto ma = match(line, rgx.src_fn_text)) {