about summary refs log tree commit diff
path: root/src/libsyntax
diff options
context:
space:
mode:
authorNiko Matsakis <niko@alum.mit.edu>2014-12-18 15:27:41 -0500
committerNiko Matsakis <niko@alum.mit.edu>2015-01-02 12:06:59 -0500
commit1b3734f8ae01a07ee3104775976b34cbb281795f (patch)
tree1743fc7e68e620738da0f263cc2d297a2f7b57c6 /src/libsyntax
parent1f887c8c5773307033fd821a5045cdc10b790ea5 (diff)
downloadrust-1b3734f8ae01a07ee3104775976b34cbb281795f.tar.gz
rust-1b3734f8ae01a07ee3104775976b34cbb281795f.zip
Fix fallout from change, adding explicit `Sized` annotations where necessary.
Diffstat (limited to 'src/libsyntax')
-rw-r--r--src/libsyntax/fold.rs2
-rw-r--r--src/libsyntax/visit.rs3
2 files changed, 2 insertions, 3 deletions
diff --git a/src/libsyntax/fold.rs b/src/libsyntax/fold.rs
index 4f0169e31f2..5234837a456 100644
--- a/src/libsyntax/fold.rs
+++ b/src/libsyntax/fold.rs
@@ -53,7 +53,7 @@ impl<T> MoveMap<T> for OwnedSlice<T> {
     }
 }
 
-pub trait Folder {
+pub trait Folder : Sized {
     // Any additions to this trait should happen in form
     // of a call to a public `noop_*` function that only calls
     // out to the folder again, not other `noop_*` functions.
diff --git a/src/libsyntax/visit.rs b/src/libsyntax/visit.rs
index 40ca6354ca6..0b4a1fbdd22 100644
--- a/src/libsyntax/visit.rs
+++ b/src/libsyntax/visit.rs
@@ -54,8 +54,7 @@ pub enum FnKind<'a> {
 /// explicitly, you need to override each method.  (And you also need
 /// to monitor future changes to `Visitor` in case a new method with a
 /// new default implementation gets introduced.)
-pub trait Visitor<'v> {
-
+pub trait Visitor<'v> : Sized {
     fn visit_name(&mut self, _span: Span, _name: Name) {
         // Nothing to do.
     }