forked from AbleScript/ablescript
No need for the associated type :D
This commit is contained in:
parent
af76443561
commit
5d81e6288f
|
@ -1,7 +1,5 @@
|
||||||
/// Host Environment Interface
|
/// Host Environment Interface
|
||||||
pub trait HostInterface {
|
pub trait HostInterface {
|
||||||
type Data;
|
|
||||||
|
|
||||||
/// Print a string
|
/// Print a string
|
||||||
fn print(&mut self, string: &str, new_line: bool) -> std::io::Result<()>;
|
fn print(&mut self, string: &str, new_line: bool) -> std::io::Result<()>;
|
||||||
|
|
||||||
|
@ -19,8 +17,6 @@ pub trait HostInterface {
|
||||||
#[derive(Clone, Copy, Default)]
|
#[derive(Clone, Copy, Default)]
|
||||||
pub struct Standard;
|
pub struct Standard;
|
||||||
impl HostInterface for Standard {
|
impl HostInterface for Standard {
|
||||||
type Data = ();
|
|
||||||
|
|
||||||
fn print(&mut self, string: &str, new_line: bool) -> std::io::Result<()> {
|
fn print(&mut self, string: &str, new_line: bool) -> std::io::Result<()> {
|
||||||
use std::io::Write;
|
use std::io::Write;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue