summaryrefslogtreecommitdiff
path: root/include/script.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/script.h')
-rw-r--r--include/script.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/script.h b/include/script.h
index af68a59..fb546ea 100644
--- a/include/script.h
+++ b/include/script.h
@@ -65,6 +65,12 @@ public:
Script(const char *source) noexcept : Script("Unknown", source, ::strlen(source)) {}
/**
+ * Constructor based on a std::string
+ * @param source PHP source code to be evaluated
+ */
+ Script(const std::string &source) noexcept : Script("Unknown", source.c_str(), source.size()) {}
+
+ /**
* Destructor
*/
virtual ~Script();