diff options
| author | Luqman Aden <laden@csclub.uwaterloo.ca> | 2013-10-25 01:56:34 -0400 |
|---|---|---|
| committer | Luqman Aden <laden@csclub.uwaterloo.ca> | 2013-11-04 23:53:11 -0500 |
| commit | c669ccf3d30da3eb505832d0872bf03607eb98eb (patch) | |
| tree | 274c13139ca8e1dfdf7934317c2c7b8be1267931 /src/libstd/reflect.rs | |
| parent | 658637baf45b41e4cff049440bc07f267d810218 (diff) | |
| download | rust-c669ccf3d30da3eb505832d0872bf03607eb98eb.tar.gz rust-c669ccf3d30da3eb505832d0872bf03607eb98eb.zip | |
libsyntax/librustc: Allow calling variadic foreign functions.
Diffstat (limited to 'src/libstd/reflect.rs')
| -rw-r--r-- | src/libstd/reflect.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/libstd/reflect.rs b/src/libstd/reflect.rs index 19fa9abc0da..c841750d7ce 100644 --- a/src/libstd/reflect.rs +++ b/src/libstd/reflect.rs @@ -382,11 +382,18 @@ impl<V:TyVisitor + MovePtr> TyVisitor for MovePtrAdaptor<V> { true } + #[cfg(stage0)] fn visit_fn_output(&mut self, retstyle: uint, inner: *TyDesc) -> bool { if ! self.inner.visit_fn_output(retstyle, inner) { return false; } true } + #[cfg(not(stage0))] + fn visit_fn_output(&mut self, retstyle: uint, variadic: bool, inner: *TyDesc) -> bool { + if ! self.inner.visit_fn_output(retstyle, variadic, inner) { return false; } + true + } + fn visit_leave_fn(&mut self, purity: uint, proto: uint, n_inputs: uint, retstyle: uint) -> bool { if ! self.inner.visit_leave_fn(purity, proto, n_inputs, retstyle) { |
