Add the ability to specify "load_module" and "use" search paths. The capability is primitive and it is currently used by chaiscript_eval to set a single path from environment variables

This commit is contained in:
Jason Turner
2010-03-18 22:53:52 +00:00
parent 7080f5d681
commit 7ac9ea7249
3 changed files with 94 additions and 25 deletions

View File

@@ -113,6 +113,18 @@ namespace chaiscript
virtual ~Eval_Error() throw() {}
};
/**
* Errors generated when loading a file
*/
struct File_Not_Found_Error : public std::runtime_error {
File_Not_Found_Error(const std::string &filename)
: std::runtime_error("File Not Found: " + filename)
{ }
virtual ~File_Not_Found_Error() throw() {}
};
/**
* Special type for returned values
*/