in reply to Re^3: Which internal DSL are there in Perl? (Domain Specific Languages - Part 1)
in thread Which internal DSL are there in Perl? (Domain Specific Languages - Part 1)
There's also Path::Class.
file("foo/bar.txt")->dir->parent->dir("baz")
It's the internal DSL equivalent of the following XPath query:
file('foo/bar.txt')->find('dir()/../baz')
Unfortunately, Path::Class wasn't designed as DSL, so it doesn't have an equivalent of
dir('.')->find('*[file()]')
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Which internal DSL are there in Perl? (Domain Specific Languages - Part 1)
by LanX (Saint) on Aug 04, 2017 at 22:20 UTC | |
by ikegami (Patriarch) on Aug 07, 2017 at 00:14 UTC | |
by LanX (Saint) on Aug 07, 2017 at 00:37 UTC |