Re: gchunt v0.2.0
On Tuesday, 5 April 2016 at 19:43:08 UTC, jmh530 wrote: On Tuesday, 5 April 2016 at 19:15:04 UTC, Pradeep Gowda wrote: This is somewhat tangentially related to the announcement.. but how does one run "-vgc" switch with "dub"? Running dmd -vgc with a project with dependencies (eg: docopt) failed because dmd could not find the dependencies. Try: "dflags-dmd": ["-vgc"], You could also make a separate configuration with this line in it so that you don't have to constantly be adding and removing it. Or `dflags "-vgc" platform="dmd"` in SDL.
Re: Release D 2.071.0
On Tuesday, 5 April 2016 at 22:43:05 UTC, Martin Nowak wrote: Glad to announce D 2.071.0. http://dlang.org/download.html This release fixes many long-standing issues with imports and the module system. See the changelog for more details. http://dlang.org/changelog/2.071.0.html -Martin module test; struct S { package int field; } void main() { S s; s.field = 1; // Deprecation: test.S.field is not visible from module test } Is this correct behavior?
Re: D Functional garden
On Monday, 29 February 2016 at 15:09:56 UTC, Seb wrote: I have started to learn D lately and as a part of my learning process I decided to put my insights into a new, open platform - the D Functional Garden. It maintains a variety of snippets that can be used to learn D or help one as a quick reference. It contrast to Guillaume Piolat's d-idioms [1], all samples are valid code and automatically tested on every run - it is basically one big unittest suite. Moreover as you might tell from the name, it focuses mostly one a functional style within D. Have a look yourself at: https://garden.dlang.io/ PS: This project is quite new, so contributions (ideas, snippets) are welcome ;-) [1] https://p0nce.github.io/d-idioms/ Nice idea. I like it.
Re: Hotfix release vibe.d 0.7.28
On Saturday, 27 February 2016 at 16:21:05 UTC, Sönke Ludwig wrote: This is a small bugfix release that mainly fixes two critical regressions: - FreeListRef!T, which is used heavily in the HTTP server code, stored its reference count in an unallocated memory region, leading to possible memory leaks or memory corruption - A TCP connection with a non-empty write buffer that got closed by the remote peer and locally at the same time could result in the calling task to starve (i.e. it got never resumed after yielding execution). In particular, this could happen when accessing HTTPS servers with the HTTP client in conjunction with "Connection: close". http://vibed.org/blog/posts/vibe-release-0.7.28 You forgot to update site header. Is there any plans on when big split will happen?
Re: blog post - "An illustrated guide to using Sublime Text 3 for D programming"
On Friday, 22 January 2016 at 04:39:00 UTC, Pradeep Gowda wrote: Sublime text 3 is a decent editor to write D code. However, getting all the different plugins working together has always proven to be somewhat of a challenge for me. So, I decided to document the process as I went along. The result is here: https://www.btbytes.com/posts/st3d.html Comments are suggestions are welcome. This webpage is not available
Re: Release vibe.d 0.7.27
On Sunday, 14 February 2016 at 08:17:34 UTC, Sönke Ludwig wrote: Am 11.02.2016 um 00:24 schrieb sigod: Did some benchmarks between `std.net.curl.get` and `vibe.http.client.requestHTTP`. Only GET requests. 100 requests, ~1.4mb file: curl total: 131304, average: 1 sec and 313 ms vibe total: 21975, average: 219 ms 52 different files: curl total: 24851, average: 477 ms vibe total: 11290, average: 217 ms 50 different files (excluded 2 of the biggest ones): curl total: 20892, average: 417 ms vibe total: 11368, average: 227 ms (Looks like `std.net.curl.get` doesn't like if file is bigger than ~1mb.) Is vibe.d's API really that fast? Or am I doing something wrong? How fast was the network connection in that case? Could it make a difference if keep-alive connections are used or not? Were the requests done in parallel or in sequence? I certainly wouldn't expect curl to be slower for a simple sequential transfer of a single file, but who knows. https://gist.github.com/sigod/c78c61ac6118fa9fda26 I'm getting something like this: HTTPS: curl total: 23401, average: 458ms vibe total: 12136, average: 237ms HTTP: curl total: 5577, average: 278ms vibe total: 4268, average: 213ms Windows 7 x86, dmd 2.070.0
Re: Sublime Text 3 Gets Better D Support
On Tuesday, 9 February 2016 at 21:08:37 UTC, Brian Schott wrote: On Wednesday, 27 January 2016 at 17:34:35 UTC, Jack Stouffer wrote: Sublime Text is a very popular text editor, and for a while now it's had marginal D support. What has changed recently is updated syntax highlighting to support all the new keywords that have come in the last couple of years and UDAs https://github.com/sublimehq/Packages/commit/b9026cf6ab8ccd05e3704d21b2d5d5cc21450aca. Syntax highlighting was mostly based on D1 before, but now it supports every thing to pure and nothrow to correctly highlighting number literals with underscores. In order to use this, you can either wait until a version of sublime is released with these changes, or you can download the dev version here https://www.sublimetext.com/3dev, and then install the new packages as described here https://github.com/sublimehq/Packages#installation. Bumping this thread because these new features are no longer in beta: build 3103 is out. https://www.sublimetext.com/3 New syntax highlighting is not as good as I expected it to be. Function definition still is not highlighted properly if line contains `;` in it. And now same happens with `.` and `*`. Highlights `inout` as function name. Doesn't highlight `assert` anymore. Etc... :/
Re: Release vibe.d 0.7.27
Did some benchmarks between `std.net.curl.get` and `vibe.http.client.requestHTTP`. Only GET requests. 100 requests, ~1.4mb file: curl total: 131304, average: 1 sec and 313 ms vibe total: 21975, average: 219 ms 52 different files: curl total: 24851, average: 477 ms vibe total: 11290, average: 217 ms 50 different files (excluded 2 of the biggest ones): curl total: 20892, average: 417 ms vibe total: 11368, average: 227 ms (Looks like `std.net.curl.get` doesn't like if file is bigger than ~1mb.) Is vibe.d's API really that fast? Or am I doing something wrong?
Re: Do D need a popular framework? like ruby's rails? or java 's ssh?
On Tuesday, 19 January 2016 at 13:22:48 UTC, beck wrote: Do D need a popular framework? in china ,a little peopel use dlang. i just use it do some simple work for myself. yet,i have learn d for a week .. i ask so many friends ,they don't use D at all.we use golang more than dlang. Oh, I thought I'll see here a suggestion to port some popular and useful libraries/frameworks from other languages... Seriously, it might be an interesting idea.
Re: Sublime Text 3 Gets Better D Support
This package might be of some help to those who doesn't want to use dev version: https://packagecontrol.io/packages/D%20Programming%20Language
Re: Programming in D – Tutorial and Reference
Actual link: https://news.ycombinator.com/item?id=10136882
Re: Release D 2.068.0
On Monday, 10 August 2015 at 14:27:47 UTC, Marc Schütz wrote: On Monday, 10 August 2015 at 14:05:14 UTC, sigod wrote: Only, why `std.digest.hmac` hasn't been included in this release? It's there, just the documentation is missing: https://github.com/D-Programming-Language/phobos/pull/3543 I don't see this module in ZIP archive. http://imgur.com/9zTAXZA
Re: Release D 2.068.0
On Monday, 10 August 2015 at 08:48:52 UTC, Martin Nowak wrote: Glad to announce D 2.068.0. http://downloads.dlang.org/releases/2.x/2.068.0/ This release comes with many rangified phobos functions, 2 new GC profilers, a new AA implementation, and countless further improvements and fixes. See the changelog for more details. http://dlang.org/changelog.html#2.068.0 -Martin Great work. Only, why `std.digest.hmac` hasn't been included in this release?
Re: DevDocs.io: voting for D
On Tuesday, 2 June 2015 at 16:42:43 UTC, sigod wrote: Hi everyone. Please vote for D to be added to https://DevDocs.io: https://trello.com/c/bCgqhZ4s/123-d 80 votes! Nice.
Re: forum.dlang.org, version 2 (BETA)
On Thursday, 4 June 2015 at 15:04:05 UTC, Vladimir Panteleev wrote: http://beta.forum.dlang.org/ When writing reply you click `Save and preview`: URL changes from http://beta.forum.dlang.org/reply/sqqngcfwtkhxeoiqn...@beta.forum.dlang.org to http://beta.forum.dlang.org/send. As does text at the top of the page (`Index » Announce » forum.dlang.org, version 2 (BETA) » Post reply` - `Index » Posting error`).
Re: forum.dlang.org, version 2 (BETA)
On Friday, 5 June 2015 at 01:52:07 UTC, Vladimir Panteleev wrote: On Friday, 5 June 2015 at 01:48:20 UTC, Meta wrote: How feasible is it to add code formatting for the web interface? Not sure what you mean. Do you mean syntax highlighting for D code? If you mean the rewrapping issues with forum.dlang.org, those should be fixed now. Code (and other text with hard line breaks) should be sent and displayed as-is. How about markdown support? It can have completely client-side implementation.
Re: forum.dlang.org, version 2 (BETA)
On Friday, 5 June 2015 at 09:53:34 UTC, Jonathan M Davis wrote: On Friday, June 05, 2015 09:16:29 sigod via Digitalmars-d-announce wrote: On Friday, 5 June 2015 at 01:52:07 UTC, Vladimir Panteleev wrote: On Friday, 5 June 2015 at 01:48:20 UTC, Meta wrote: How feasible is it to add code formatting for the web interface? Not sure what you mean. Do you mean syntax highlighting for D code? If you mean the rewrapping issues with forum.dlang.org, those should be fixed now. Code (and other text with hard line breaks) should be sent and displayed as-is. How about markdown support? It can have completely client-side implementation. Remember that the forum software is just a frontend for an nntp server and that others view the content via nntp or via the mailing list. This just scares off users who doesn't have experience with all this stuff. And I believe now there's much more users, who doesn't even heard of NNTP, than whose who worked with it. So, it doesn't make any sense to support features that involve anything other than plain text. It would just result in garbage/cruft in the messages for those viewing it elsewhere than the forums. Markdown in a raw format is very readable. As for me, it's easier to read raw markdown than mix of text and code. So, while it might be nice to have markdown if we were dealing purely with forum software, we're not, so it doesn't make sense. I don't see a reason why forum cannot have features on it's own. Especially, when this features won't significantly affect other ways to access the same information.
Re: forum.dlang.org, version 2 (BETA)
On Friday, 5 June 2015 at 10:48:31 UTC, ketmar wrote: On Fri, 05 Jun 2015 10:19:20 +, sigod wrote: This just scares off users who doesn't have experience with all this stuff. And I believe now there's much more users, who doesn't even heard of NNTP, than whose who worked with it. i vote for dropping web interface at all. i believe that everybody should use NNTP reader. Bad joke. It'll probably kill D in a long run.
Re: forum.dlang.org, version 2 (BETA)
On Friday, 5 June 2015 at 10:54:03 UTC, Jonathan M Davis wrote: On Friday, June 05, 2015 10:19:20 sigod via Digitalmars-d-announce wrote: Markdown in a raw format is very readable. As for me, it's easier to read raw markdown than mix of text and code. Perhaps, but I don't want to see raw markdown in e-mails any more than I want to see raw html, even if raw markdown isn't quite as bad. Your comparison of markdown and HTML doesn't make any sense. They're fundamentally different. So, while it might be nice to have markdown if we were dealing purely with forum software, we're not, so it doesn't make sense. I don't see a reason why forum cannot have features on it's own. Especially, when this features won't significantly affect other ways to access the same information. If you're screwing with the content of the messages, then yes, it does affect the other ways that the information is accessed - and that includes adding stuff like markdown or html into the messages. If it's something that just affects how the content is viewed in the web forum, then that's fine, but it needs to not mess with the content of the messages Are you sure you aren't confusing something like [bbcodes] with [markdown]? I don't see how markdown can obscure message. For example, this quotes (``) are part of markdown. or assume that all (or even a majority) of the users are communicating via the web forum. You missed my point. I was talking about _potential_ users. Aren't we all want for D to became very popular and broadly used? [bbcodes]: https://en.wikipedia.org/wiki/BBCode [markdown]: https://en.wikipedia.org/wiki/Markdown
Re: forum.dlang.org, version 2 (BETA)
On Friday, 5 June 2015 at 12:57:23 UTC, Vladimir Panteleev wrote: 1. People receiving messages through NNTP/mailing lists will not see the formatted Markdown. That isn't a problem at all. Although Markdown's goal is to be readable in its plain text source code, it still allows many situations in which the source is misleading or difficult to understand. For example, special characters need to be escaped by a backslash, which can create confusion in the presence of other special characters. (Are they part of the D syntax the user is describing, or something else?) Some syntax such as tables or images can also be not very readable in source form. I cannot speculate about it without actually trying to implement it. 2. How should we render messages sent by NNTP/mailing-list users? Why should we? Do we just assume that they're sending Markdown and render it as such? Yes. You already do it for quotes. This can cause the messages to appear broken to forum users. Yes, it can be a problem. But, first: markdown render should be optional. And second: don't render if you're not sure how to render it. 3. There is no unified standard for Markdown. The original format is not used on major sites today - StackOverflow and GitHub extend the format, and users will expect Markdown with those extensions. There's always should be a help which explains what supported. Also, I don't think we need _all_ syntax and all possible extensions. Just those which will improve readability. 4. Markdown's formatting for code (leading whitespace) is rather cumbersome I dislike this syntax too. GitHub's extension: ```[language, optional] code in here ``` Is much better. , and difficult to use without either visual JavaScript text editors (as on SO) or Markdown extensions (as on GH). You already have `Save and preview` button. 5. You can't edit posts once sent. This means that if you accidentally messed up the formatting (e.g. you pasted code without padding it with whitespace or surrounding it in ```...``` blocks), you can't go back and edit it now. I'm aware of that. As I said before: don't render if you're not sure how to render it. You see this all the time on StackOverflow (even though it's user-editable) and more importantly on the vibe.d forums. It's pretty ugly It all depends on actual users. We can't do anything about this. 6. How do we encode that the message is in Markdown in the message's headers? Again. Why should we? See #2.
Re: forum.dlang.org, version 2 (BETA)
On Thursday, 4 June 2015 at 20:25:02 UTC, sigod wrote: Few issues with help dialog (opened with Shift+H): - Centers on full page instead of only visible part of it. - Scrolls with page. `fixed` instead of [`absolute`][0] and it should be fixed. (Heh, funny.) Also, I believe closing popup on `mouseup` in popup itself doesn't create good UX. Better to close it on `click` outside of popup (maybe difficult to implement without overlay) and to provide an X (close) button in popup. [0]: https://github.com/CyberShadow/DFeed/blob/next/web/static/css/dfeed.css#L898
Re: forum.dlang.org, version 2 (BETA)
On Thursday, 4 June 2015 at 21:32:36 UTC, Vladimir Panteleev wrote: Chrome weirdness. Push fixed. Thanks. It was fast. :)
Re: forum.dlang.org, version 2 (BETA)
On Thursday, 4 June 2015 at 21:08:04 UTC, Vladimir Panteleev wrote: On Thursday, 4 June 2015 at 20:56:33 UTC, sigod wrote: On Thursday, 4 June 2015 at 20:25:02 UTC, sigod wrote: Few issues with help dialog (opened with Shift+H): - Centers on full page instead of only visible part of it. - Scrolls with page. `fixed` instead of [`absolute`][0] and it should be fixed. (Heh, funny.) Thanks, fixed. Also, I believe closing popup on `mouseup` in popup itself doesn't create good UX. Better to close it on `click` outside of popup (maybe difficult to implement without overlay) and to provide an X (close) button in popup. Yes, you're right. The popup isn't a big part of the UI, however, and you can dismiss it by pressing any key. I'll try to create PR for this in upcoming days. Also, I just noticed: when you open direct link linked post appears on the bottom of the page instead of the top. For example: http://beta.forum.dlang.org/post/gbzgmtrjpnsexfasx...@beta.forum.dlang.org
Re: forum.dlang.org, version 2 (BETA)
On Thursday, 4 June 2015 at 15:38:57 UTC, Vladimir Panteleev wrote: On Thursday, 4 June 2015 at 15:33:56 UTC, extrawurst wrote: On Thursday, 4 June 2015 at 15:04:05 UTC, Vladimir Panteleev wrote: [...] Wow its insanely fast! i have some issues with the shortcuts. i have a german keyboard and ? is Shift+.. combo and i cant open the shortcut help. Code in question: https://github.com/CyberShadow/DFeed/blob/next/web/static/js/dfeed.js#L645-L646 Can you propose a patch? Shift+? returns key code 191. And `String.fromCodePoint(191) === '¿'`.
Re: forum.dlang.org, version 2 (BETA)
On Thursday, 4 June 2015 at 20:07:26 UTC, Vladimir Panteleev wrote: On Thursday, 4 June 2015 at 19:55:28 UTC, sigod wrote: On Thursday, 4 June 2015 at 15:38:57 UTC, Vladimir Panteleev wrote: On Thursday, 4 June 2015 at 15:33:56 UTC, extrawurst wrote: [...] Code in question: https://github.com/CyberShadow/DFeed/blob/next/web/static/js/dfeed.js#L645-L646 Can you propose a patch? Shift+? returns key code 191. And `String.fromCodePoint(191) === '¿'`. I looked into this. 191 is actually the code for the '/' key. This means that checking for it doesn't work on layouts where the question mark is typed by pressing another button. Does this work for you? I tried it on the Russian layout (where it's on Shift+7) and it doesn't. I settled by moving the help key to Shift+H. Hm. Actually 63 key code will appear on `keypress` event. And 191 on `keydown`. (But you use `keydown` for webkit.)
Re: forum.dlang.org, version 2 (BETA)
On Thursday, 4 June 2015 at 20:30:38 UTC, sigod wrote: On Thursday, 4 June 2015 at 20:07:26 UTC, Vladimir Panteleev wrote: On Thursday, 4 June 2015 at 19:55:28 UTC, sigod wrote: On Thursday, 4 June 2015 at 15:38:57 UTC, Vladimir Panteleev wrote: [...] Shift+? returns key code 191. And `String.fromCodePoint(191) === '¿'`. I looked into this. 191 is actually the code for the '/' key. This means that checking for it doesn't work on layouts where the question mark is typed by pressing another button. Does this work for you? I tried it on the Russian layout (where it's on Shift+7) and it doesn't. I settled by moving the help key to Shift+H. Hm. Actually 63 key code will appear on `keypress` event. And 191 on `keydown`. (But you use `keydown` for webkit.) Take a look here: http://stackoverflow.com/a/29494190/944911
Re: forum.dlang.org, version 2 (BETA)
On Thursday, 4 June 2015 at 15:33:56 UTC, extrawurst wrote: i have some issues with the shortcuts. i have a german keyboard and ? is Shift+.. combo and i cant open the shortcut help. I cannot open it too. Both in Chrome 43 and Firefox 38.
Re: forum.dlang.org, version 2 (BETA)
On Thursday, 4 June 2015 at 19:42:09 UTC, Vladimir Panteleev wrote: On Thursday, 4 June 2015 at 17:57:26 UTC, Mr. Anonymous wrote: * Space to scroll doesn't work. Where? In threads. But works on help page.
Re: forum.dlang.org, version 2 (BETA)
On Thursday, 4 June 2015 at 20:05:32 UTC, Vladimir Panteleev wrote: On Thursday, 4 June 2015 at 19:57:20 UTC, sigod wrote: On Thursday, 4 June 2015 at 19:42:09 UTC, Vladimir Panteleev wrote: On Thursday, 4 June 2015 at 17:57:26 UTC, Mr. Anonymous wrote: * Space to scroll doesn't work. Where? In threads. But works on help page. Should be fixed now. Yes. It works now. Few issues with help dialog (opened with Shift+H): - Centers on full page instead of only visible part of it. - Scrolls with page. On Thursday, 4 June 2015 at 20:07:26 UTC, Vladimir Panteleev wrote: On Thursday, 4 June 2015 at 19:55:28 UTC, sigod wrote: Shift+? returns key code 191. And `String.fromCodePoint(191) === '¿'`. I looked into this. 191 is actually the code for the '/' key. This means that checking for it doesn't work on layouts where the question mark is typed by pressing another button. Does this work for you? I tried it on the Russian layout (where it's on Shift+7) and it doesn't. I settled by moving the help key to Shift+H. Well. Shift+/ works on GitHub and StackOverflow. As do Shift+7 on Russian layout. You can find line like this in GitHub's sources: `i={...,191:?,...}`. So, I suppose it's better to use key codes directly.
Re: DevDocs.io: voting for D
On Tuesday, 2 June 2015 at 17:35:19 UTC, tired_eyes wrote: http://forum.dlang.org/thread/mjnscnoxgoxvoymgi...@forum.dlang.org Dang it! When I checked google wasn't showing this post in the search results.
DevDocs.io: voting for D
Hi everyone. Please vote for D to be added to https://DevDocs.io: https://trello.com/c/bCgqhZ4s/123-d About DevDocs (copy-pasted from index page): ``` DevDocs combines multiple API documentations in a fast, organized, and searchable interface. Here's what you should know before you start: - You don't have to use your mouse — see the list of keyboard shortcuts - The search supports fuzzy matching (e.g. bgcp brings up background-clip) - To search a specific documentation, type its name (or an abbreviation), then Tab - You can search using your browser's address bar - DevDocs works offline, on mobile, and can be installed on Chrome and Firefox. - DevDocs is free and open source ``` I use it very often for JavaScript. And I would like to use it for D. P.S. I'm surprised there's no such thread on the forum.