mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 03:51:18 +00:00
Refactor protocols.
This commit is contained in:
committed by
Christoffer Lerno
parent
f3e3aa231d
commit
99cfaa1583
@@ -14,7 +14,7 @@ fault PathResult
|
||||
NO_PARENT,
|
||||
}
|
||||
|
||||
struct Path
|
||||
struct Path (Printable)
|
||||
{
|
||||
String path_string;
|
||||
PathEnv env;
|
||||
@@ -449,12 +449,12 @@ fn void Path.free(self)
|
||||
}
|
||||
|
||||
|
||||
fn usz! Path.to_format(&self, Formatter* formatter) : Printable
|
||||
fn usz! Path.to_format(&self, Formatter* formatter) @dynamic
|
||||
{
|
||||
return formatter.print(self.str_view());
|
||||
}
|
||||
|
||||
fn String Path.to_string(&self, Allocator* using = mem::heap()) : Printable
|
||||
fn String Path.to_string(&self, Allocator* using = mem::heap()) @dynamic
|
||||
{
|
||||
return self.str_view().copy(using);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user