Re: [rust-dev] lib: Is anybody working on the datetime library?
Hello Chris, That article by Erik Naggum looks deeply interesting. Just loaded it to read in bed in a few hours tonight. Thanks for your input. Might ask you a few questions in the near future. Luis On 19 September 2013 20:57, Chris Peterson cpeter...@mozilla.com wrote: A Rust datetime library has been on my to-do list for a long time. :) JSR-310 is a very complete solution, but it carries a lot of Java baggage. C++11's std::chrono library [1] defines a smaller API for time points and durations without calendars (i.e. the hard part). std::chrono's API might be more rustic than JSR-310's because C++ and Rust have operator overloading. I strongly recommend reading Erik Naggum's The Long, Painful History of Time [2] about Common Lisp's support for the concept of time as humans experience it. :) [1] http://msdn.microsoft.com/en-**us/library/hh874757.aspxhttp://msdn.microsoft.com/en-us/library/hh874757.aspx [2] http://naggum.no/lugm-time.**html http://naggum.no/lugm-time.html chris __**_ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/**listinfo/rust-devhttps://mail.mozilla.org/listinfo/rust-dev ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev
Re: [rust-dev] Rust's newest full-time Engineer
Congrats Alex! and thank you :) It is fantastic to see Rust and its community grow at such an amazing pace. Luis On 16 September 2013 17:03, Brian Anderson bander...@mozilla.com wrote: On 09/16/2013 01:43 PM, Alex Crichton wrote: Greetings rust-dev! I wanted to announce to everyone that today is my first day at Mozilla as an engineer working on Rust! Welcome aboard! __**_ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/**listinfo/rust-devhttps://mail.mozilla.org/listinfo/rust-dev ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev
Re: [rust-dev] Resources for newbies
FF, The rust-for-real is great. I've read through it and it was very educational about Tasks Management. I think people would be interested if you gave them precise things you want added to your project. I think it would be very interesting if you started a thread in this mailing list about it. John, The Rust Tour (same as Go Tour but in Rust) would be awesome. Definite +1 here. Cheers! Luis On 14 September 2013 18:42, Flaper87 flape...@gmail.com wrote: 2013/9/15 John Mija jon...@proinbox.com Since Rust is close to 0.8 (with a syntax almost stable), each time there will be more interest to be learned by newbies (like me) so I think that could help some resources if were converted to Rust: + The tour of Go (http://tour.golang.org/) is licensed under Apache https://code.google.com/p/go-**tour/https://code.google.com/p/go-tour/ + A graphical web-based front-end for gdb https://github.com/**sirnewton01/godbg/https://github.com/sirnewton01/godbg/ FWIW, I've started this[0] and I'll be adding more things in the next couple of weeks. I'd love to have some help from other folks if they want. :D [0] https://github.com/FlaPer87/rust-for-real Cheers, FF -- Flavio (@flaper87) Percoco http://www.flaper87.com http://github.com/FlaPer87 ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev
Re: [rust-dev] Rust for real: Learning Rust by example
Nice! Looking forward to this covering more modules. Hopefully I will have time to contribute sometime soon. FF (I assume that is how you want to be called), Could you populate the Readme file with more information about the project? It would get more people interested in it. Luis On 15 September 2013 11:34, Brian Uhrin brianuh...@gmail.com wrote: On Sun, Sep 15, 2013 at 5:50 AM, Flaper87 flape...@gmail.com wrote: Hi Guys, I'm writing this email in the hope of finding some help from you. I recently started this project[0] into which I'll be adding examples of Rust's internal modules - starting from std and then extra - as small programs that can be compiled and ran independently. As for now, there are 2 examples for tasks already. If any of you feels confident enough with any of Rusts modules and wants to write examples - with docstrings and README explaining what's happening - please, feel free to send PR. I created a dir for task's examples into which I put 2 rust files -I'll add more later - with contextualized examples. The first is a simple example of how to use tasks and the second shows how to use nested tasks. I'm planning to add another for inter tasks communications and another for tasks control - supervised, unlinked, poisoning tasks, etc. I think this structure would work well for other modules as well. I'm also planning to add support for rustpkg and let it build the whole thing if someone wants to do that. If you have any better idea, suggestion please, share. Cheers, FF [0] https://github.com/FlaPer87/rust-for-real I am currently taking an independent study class at the University of Pittsburgh and chose Rust as the topic. I planned to have the project consist of a beginners tutorial, some non-trivial code examples, an overview and code examples from the servo project, and some examples of c/c++ memory safety issues that Rust is trying to avoid. Right now I am still learning and have played in std and extra. I will be doing a lot more work there and hopefully I will develop some examples that I can add to your project. Brian ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev
Re: [rust-dev] lib: Is anybody working on the datetime library?
Hello all, I've created this repository as a placeholder: https://github.com/luisbg/rust-datetime It won't have much content for a while since I won't commit until there is at least one usable API function, and I'm currently in the researching and planning stage. Patience. Thanks, Luis On 13 September 2013 21:09, Luis de Bethencourt l...@debethencourt.comwrote: That is a very interesting read. We certainly should learn from the experiences of other languages. This being a good example. I will be revisiting the linked documents listed in this thread repeatedly. Fortunately the issue he mentions about NULLs creating random bugs, is taken care of by Rust's safety. Thanks, Luis On 13 September 2013 19:21, Jason Fager jfa...@gmail.com wrote: Joda-Time and JSR-310 are similar APIs but different implementations. It's the same guy behind both, here he is explaining why he wanted 310 instead of just standardizing Joda: http://blog.joda.org/2009/11/why-jsr-310-isn-joda-time_4941.html?m=1 On Friday, September 13, 2013, Luis de Bethencourt wrote: Cool! Great and awesome feedback. The summary is that Joda-Time is what we should aspire to have. My goal is to first cover the most common use cases, and as Corey says, easy to use correctly. After that I can start considering the corner cases like bya and mya. Which sound very fun and interesting, but not high priority. Hopefully by then I won't be too consumed by the question of what is Time. Thanks, will keep you guys updated, Luis On 13 September 2013 16:20, Thad Guidry thadgui...@gmail.com wrote: Additionally, Be able to convert bya to mya ? http://en.wikipedia.org/wiki/Bya The short scale is now commonly used, btw... but also need to deal with this for conversions: http://en.wikipedia.org/wiki/Long_and_short_scales There should be a preference boolean for conversion output for short or long scale... especially concerning above a thousand million. That's enough to get you going with some wild ideas that Jodatime does not handle. On Fri, Sep 13, 2013 at 3:08 PM, Thad Guidry thadgui...@gmail.comwrote: One idea and use case for Paleontologists and Geologists coming over to Rust in droves... :-) Generically, just be able to handle simple Geologic addition and subtraction against an Epoch itself (reference date) http://en.wikipedia.org/wiki/Epoch_(reference_date) using known abbreviations. And additionally, store, understand, and output them: B.Y.B.P = Billion Years Before Present M.Y.B.P = Million Years Before Present On Fri, Sep 13, 2013 at 2:51 PM, Aaron Dandy aaron.da...@live.comwrote: I remember reading this article: http://noda-time.blogspot.com/2011/08/what-wrong-with-datetime-anyway.html a while back and really appreciating date time time zone libraries. Also after reading news of the leap second triggering a bug on a bunch of systems I now question all assumptions I make about our representations of time. I can no longer say that a minute is 60 seconds long with a straight face. Next up I guess we programmers have a year 2038 problem to deal with too. This library will be a big deal to write but there thankfully there should be a lot of existing knowledge to learn from. -- Date: Fri, 13 Sep 2013 15:10:21 -0400 From: l...@debethencourt.com To: s...@scientician.net CC: rust-dev@mozilla.org Subject: Re: [rust-dev] lib: Is anybody working on the datetime library? Hello Bardur, Thank you so much for the reference resource of JSR-310 and its design docs. I looked over it briefly and it is indeed very valuable. It was listed in the wiki page, but the link was to the former home of it. I have updated it. Since nobody has claimed this module, I will start working on this module tomorrow Saturday. Is that OK? Please, please, I would love more comments and ideas. Will start asking for reviews once I have some code to show. Thanks, Luis On 13 September 2013 00:57, Bardur Arantsson spam@scientici ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev
Re: [rust-dev] lib: Is anybody working on the datetime library?
Hello Bardur, Thank you so much for the reference resource of JSR-310 and its design docs. I looked over it briefly and it is indeed very valuable. It was listed in the wiki page, but the link was to the former home of it. I have updated it. Since nobody has claimed this module, I will start working on this module tomorrow Saturday. Is that OK? Please, please, I would love more comments and ideas. Will start asking for reviews once I have some code to show. Thanks, Luis On 13 September 2013 00:57, Bardur Arantsson s...@scientician.net wrote: On 2013-09-12 22:12, Luis de Bethencourt wrote: Hello everyone, I'm interested in helping with some module development. A good way to learn Rust by using it and help Rust at the same time. Of the wanted modules in this page: https://github.com/mozilla/rust/wiki/Libs I see that this page does have a link to design docs for JSR-310 which is probably a good bet as to a usable DateTime API design (for Java at least). I just thought I'd mention that the documentation for the nearly final (i.e. barring serious bugs) API has been released at: http://download.java.net/jdk8/docs/technotes/guides/datetime/index.html Even if this is for Java, the design decisions about how the conepts of date/time are modeled (Instant vs. *DateTime, Periods, Durations, etc.) would apply in any language. They are also all essential concepts when working seriously with date/time even though the distinctions may not appear so at first. (I should mention that the lead on the JSR-310 spec was also the author of JodaTime which gets much deserved credit by Java developers for bringing date/time manipulation on the JVM out of the dark ages of java.util.Date. JSR-310 is a slightly reworked/simplified version of that API, so it's a sort of what are the essentials? version of JodaTime.) Regards, ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev
Re: [rust-dev] lib: Is anybody working on the datetime library?
That is a very interesting read. We certainly should learn from the experiences of other languages. This being a good example. I will be revisiting the linked documents listed in this thread repeatedly. Fortunately the issue he mentions about NULLs creating random bugs, is taken care of by Rust's safety. Thanks, Luis On 13 September 2013 19:21, Jason Fager jfa...@gmail.com wrote: Joda-Time and JSR-310 are similar APIs but different implementations. It's the same guy behind both, here he is explaining why he wanted 310 instead of just standardizing Joda: http://blog.joda.org/2009/11/why-jsr-310-isn-joda-time_4941.html?m=1 On Friday, September 13, 2013, Luis de Bethencourt wrote: Cool! Great and awesome feedback. The summary is that Joda-Time is what we should aspire to have. My goal is to first cover the most common use cases, and as Corey says, easy to use correctly. After that I can start considering the corner cases like bya and mya. Which sound very fun and interesting, but not high priority. Hopefully by then I won't be too consumed by the question of what is Time. Thanks, will keep you guys updated, Luis On 13 September 2013 16:20, Thad Guidry thadgui...@gmail.com wrote: Additionally, Be able to convert bya to mya ? http://en.wikipedia.org/wiki/Bya The short scale is now commonly used, btw... but also need to deal with this for conversions: http://en.wikipedia.org/wiki/Long_and_short_scales There should be a preference boolean for conversion output for short or long scale... especially concerning above a thousand million. That's enough to get you going with some wild ideas that Jodatime does not handle. On Fri, Sep 13, 2013 at 3:08 PM, Thad Guidry thadgui...@gmail.comwrote: One idea and use case for Paleontologists and Geologists coming over to Rust in droves... :-) Generically, just be able to handle simple Geologic addition and subtraction against an Epoch itself (reference date) http://en.wikipedia.org/wiki/Epoch_(reference_date) using known abbreviations. And additionally, store, understand, and output them: B.Y.B.P = Billion Years Before Present M.Y.B.P = Million Years Before Present On Fri, Sep 13, 2013 at 2:51 PM, Aaron Dandy aaron.da...@live.comwrote: I remember reading this article: http://noda-time.blogspot.com/2011/08/what-wrong-with-datetime-anyway.html a while back and really appreciating date time time zone libraries. Also after reading news of the leap second triggering a bug on a bunch of systems I now question all assumptions I make about our representations of time. I can no longer say that a minute is 60 seconds long with a straight face. Next up I guess we programmers have a year 2038 problem to deal with too. This library will be a big deal to write but there thankfully there should be a lot of existing knowledge to learn from. -- Date: Fri, 13 Sep 2013 15:10:21 -0400 From: l...@debethencourt.com To: s...@scientician.net CC: rust-dev@mozilla.org Subject: Re: [rust-dev] lib: Is anybody working on the datetime library? Hello Bardur, Thank you so much for the reference resource of JSR-310 and its design docs. I looked over it briefly and it is indeed very valuable. It was listed in the wiki page, but the link was to the former home of it. I have updated it. Since nobody has claimed this module, I will start working on this module tomorrow Saturday. Is that OK? Please, please, I would love more comments and ideas. Will start asking for reviews once I have some code to show. Thanks, Luis On 13 September 2013 00:57, Bardur Arantsson spam@scientici ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev
[rust-dev] lib: Is anybody working on the datetime library?
Hello everyone, I'm interested in helping with some module development. A good way to learn Rust by using it and help Rust at the same time. Of the wanted modules in this page: https://github.com/mozilla/rust/wiki/Libs I'm attracted to datetime: https://github.com/mozilla/rust/wiki/Lib-datetime Just want to make sure there isn't anybody working on this to avoid accidental duplication. Thanks, Luis ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev
Re: [rust-dev] This Week in Rust
Thanks Corey! This updates are great to keep track of all things Rust. Kudos :) Luis On 12 September 2013 17:28, Corey Richardson co...@octayn.net wrote: Sorry it is late; it has been on my blog and reddit, but I forgot to post it here. Content copied from http://cmr.github.io/blog/2013/09/07/this-week-in-rust/ -- Welcome to another *This Week in Rust*. # What's cooking in master? 65 pull requests were merged this week, and bors has had some idle time when there wasn't anything approved in the queue. ## Breaking changes - `std::os::glob` has been replaced with a [pure Rust version](https://github.com/mozilla/rust/pull/8914), for cross-platform and compatability reasons. - `std::str::from_bytes` has been [renamed](https://github.com/mozilla/rust/pull/8997) to `std::str::from_utf8`, to be explicit about what it accepts. - Casting to bool with `as` is [no longer allowed](https://github.com/mozilla/rust/pull/8980), and surrogate characters are no longer allowed in strings. - char is [no longer](https://github.com/mozilla/rust/pull/8974) treated as an integer type (meaning it can't be casted to/from them), which removes the ability for safe code to create invalid characters. - Opening a listening socket and actually listening on it [have been split](https://github.com/mozilla/rust/pull/8954). If you're jiggy with the jive, listen and accept are now separate operations. (*ed*: this used to say bind and accept wereseparate; thanks to ecr for the correction.) ## Additions - `let` var hygiene has [landed](https://github.com/mozilla/rust/pull/9026 ). I'm sure this has cool implications, but I don't really know what they are. - An [`export_name` attribute](https://github.com/mozilla/rust/pull/8903) has been added to control what symbol name something is exported as (similar to `no_mangle`). - An `ExactSize` trait [has been added](https://github.com/mozilla/rust/pull/8884) to mark an iterator that always accurately reports its size in the `size_hint` method. - `ToStr` has been [implemented](https://github.com/mozilla/rust/pull/8960 ) for char and Ascii. - Safe accessors of `MutexArc` [have been implemented](https://github.com/mozilla/rust/pull/8966) - A bytes iterator [has been added]( https://github.com/mozilla/rust/pull/8935) for newrt readers. - Stream is [automatically implemented](https://github.com/mozilla/rust/pull/8984) for types which implement Reader and Writer from newrt. - An `unreachable` macro [has been added](https://github.com/mozilla/rust/pull/8992) for better error reporting than a function could do. - newrt [can now do](https://github.com/mozilla/rust/pull/9000) simple DNS resolution. - strptime/strftime [now support]( https://github.com/mozilla/rust/pull/9016) fractional seconds, out to tenths of a nanosecond. ## Changes etc - Name mangling [has been improved](https://github.com/mozilla/rust/pull/8875). - `rust_log.cpp` [has been converted](https://github.com/mozilla/rust/pull/8880) into pure Rust. - Debuginfo [now does closure capture](https://github.com/mozilla/rust/pull/8855) and very large structs. - A [bunch](https://github.com/mozilla/rust/pull/8947) [of](https://github.com/mozilla/rust/pull/8927) [repr](https://github.com/mozilla/rust/pull/8928) improvements landed. # Meeting There was no meteting this week listed on the wiki or that I saw. # Projects - [rust-nanomsg](https://github.com/glycerine/rust-nanomsg) - bindings to the nanomsg library. ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev ___ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev