2016-09-01 16:42:28 +00:00
|
|
|
#ifndef CS_REPL_HAS_EDIT
|
|
|
|
/* use nothing (no line editing support) */
|
|
|
|
|
2017-01-30 18:38:11 +00:00
|
|
|
#include <optional>
|
|
|
|
|
2016-09-01 16:42:28 +00:00
|
|
|
#include <ostd/string.hh>
|
|
|
|
|
2017-06-19 18:13:54 +00:00
|
|
|
inline void init_lineedit(cs_state &, ostd::string_range) {
|
2016-09-01 16:42:28 +00:00
|
|
|
}
|
|
|
|
|
2017-06-19 18:13:54 +00:00
|
|
|
inline std::optional<std::string> read_line(cs_state &, cs_svar *pr) {
|
2016-09-01 16:42:28 +00:00
|
|
|
ostd::write(pr->get_value());
|
2020-09-11 21:41:09 +00:00
|
|
|
return ostd::cin.get_line(ostd::appender<std::string>()).get();
|
2016-09-01 16:42:28 +00:00
|
|
|
}
|
|
|
|
|
2017-06-19 18:13:54 +00:00
|
|
|
inline void add_history(cs_state &, ostd::string_range) {
|
2016-09-01 16:42:28 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|