Re: [rust-dev] Autiincrement values in loops

2013-02-01 Thread Josh Matthews
The int/uint::range methods would seem to do the job: for uint::range(0, 10) |i| { io::println(fmt!(%u, i)); } Cheers, Josh On 1 February 2013 12:14, Alexander Stavonin a.stavo...@gmail.com wrote: Have we a pretty looks solution for auto incrementation counters during loops? I mean something

Re: [rust-dev] Autiincrement values in loops

2013-02-01 Thread Josh Matthews
Actually my first suggestion won't work except in trivial circumstances (ie. starting from zero). Sorry. On 1 February 2013 12:32, Josh Matthews j...@joshmatthews.net wrote: Well, constant increments of N can be simulated with |let i = i * N;| in the body of the loop. There's an issue open

Re: [rust-dev] FastCGI implementation

2013-04-08 Thread Josh Matthews
There's a very basic POSIX socket binding at https://github.com/jdm/rust-socket. It's been neglected for a bit, I would quickly merge a PR to update it to 0.6. Cheers, Josh On 8 April 2013 02:14, Andres Osinski andres.osin...@gmail.com wrote: Are the libUV bindings for the socket API the

Re: [rust-dev] [GSoC 2013] May I ask some questions about the Rust debugging symbols idea ?

2013-04-22 Thread Josh Matthews
Hi Greg, These questions are fine. The key point you're missing in the existing debug code is that most of the functions in debuginfo.rs are called from within functions like create_local_var. I just realized that I linked to the potentially outdated version of the file on the master branch;

Re: [rust-dev] Summer of Code 2013: Rust Debug Symbol Generation

2013-05-29 Thread Josh Matthews
On 29 May 2013 17:00, Wojciech Matyjewicz wmatyjew...@fastmail.fm wrote: The other benefit is that DIBuilder keeps track of what metadata nodes it has generated and reuses the existing nodes instead of generating identical ones --- similar functionality from debuginfo.rs could be removed then.

Re: [rust-dev] Bus error: 10

2013-08-28 Thread Josh Matthews
That's covered by https://github.com/mozilla/rust/issues/4363https://github.com/mozilla/rust/issues/4363in the issue tracker. Cheers, Josh On 28 August 2013 19:39, Amitava Shee amitava.s...@gmail.com wrote: I am getting a Bus error - please see the following.Should I file this as an issue in

Re: [rust-dev] Out of -Z flags

2013-09-03 Thread Josh Matthews
We could free one up by moving basic debug-info back into the -g flag. Now that we have automated tests, it's a lot less likely to get busted and frustrate people. On 3 September 2013 14:34, Corey Richardson co...@octayn.net wrote: Right now Z flags are implemented using a bit flag stored in a

Re: [rust-dev] autotrace

2013-09-30 Thread Josh Matthews
Please note that Michael Woerister's work this summer on debug symbols has been wildly successful, and it's worth giving it another shot before looking into further compiler hacking: http://michaelwoerister.github.io/2013/09/27/what-you-call-the-present.html Cheers, Josh On 30 September 2013

Re: [rust-dev] list of all reserved keywords of the language

2013-11-19 Thread Josh Matthews
http://static.rust-lang.org/doc/master/rust.html#keywords Cheers, Josh On 19 November 2013 17:06, Gaetan gae...@xeberon.net wrote: hello Where can I find an exhaustive list of the keywords defined by the language? I want to add basic syntax highlighting support to the rust language to

Re: [rust-dev] any tips and tricks for faster compilation of compiler itself?

2013-11-27 Thread Josh Matthews
I recommend 'make rustc-stage1' to ensure that your changes build, then 'make check-stage1' to run tests like compile-fail/run-fail/run-pass. Cheers, Josh On 27 November 2013 22:37, Ömer Sinan Ağacan omeraga...@gmail.com wrote: Hello everyone, I'm trying to make some changes on the Rust

Re: [rust-dev] Compile-time function evaluation in Rust

2014-01-28 Thread Josh Matthews
Out of that list of requirements, #5 (doesn't perform I/O actions) is the one that strikes me as least well-defined. Could you elaborate on how you would enforce it? Cheers, Josh On 28 January 2014 14:15, Pierre Talbot ptal...@hyc.io wrote: Hi, The Mozilla foundation proposes research

Re: [rust-dev] Virtual fn is a bad idea

2014-03-12 Thread Josh Matthews
Is the 'all nodes consuming same amount of memory' too much memory? Unfortunately yes, this is a very big problem. This solution has been discussed in the past, but some of the elements types necessarily contain far more members than others, and this would absolutely destroy memory usage in the

Re: [rust-dev] Refactor json.rs

2014-03-22 Thread Josh Matthews
() } and ask rustc to infer a proper type parameter. That would be global inference. -Ed On Sat, Mar 22, 2014 at 11:43 PM, Josh Matthews j...@joshmatthews.netwrote: m here is merely a local variable but Encoder'a requires a lifetime at least 'a This statement does not make sense to me

Re: [rust-dev] Vector length specified by enum

2014-03-24 Thread Josh Matthews
Nope; we can't use casts of enum values in type signatures. This is discussed in https://github.com/mozilla/rust/issues/5873 . Cheers, Josh On 24 March 2014 11:26, Patrick Walton pcwal...@mozilla.com wrote: On 3/24/14 2:45 AM, Richo Healey wrote: I get a compile error:

[rust-dev] Single inheritance example

2014-03-31 Thread Josh Matthews
As one of the main DOM designers for Servo, I've been reading the RFCs for virtual struct proposals with interest. One problem I've had is that I have found it difficult to translate the examples included into meaningful commentary with regards to how this would impact Servo's implementation.

Re: [rust-dev] Rust Research Project Query

2014-10-09 Thread Josh Matthews
Finishing the DXR (https://wiki.mozilla.org/DXR) support for Rust that Nick Cameron started would be extremely valuable and intersect with your static analysis interests. https://bugzilla.mozilla.org/show_bug.cgi?id=956768 is our tracking metabug for the DXR-side work that is still required;