Re: "I made a game using Rust"

2017-05-10 Thread JN via Digitalmars-d
On Wednesday, 10 May 2017 at 18:20:01 UTC, zetashift wrote: On Wednesday, 10 May 2017 at 12:52:34 UTC, JN wrote: I wonder, would it be possible for D in the current state to achieve the same? I imagine iOS isn't possible yet and Android is just getting there? Reading this thread while going

Re: Access specifiers and visibility

2017-05-10 Thread Jesse Phillips via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 13:29:40 UTC, Andrew Edwards wrote: On Wednesday, 10 May 2017 at 13:13:46 UTC, Jesse Phillips wrote: On Wednesday, 10 May 2017 at 01:42:47 UTC, Andrew Edwards wrote: Attempting to update a git repo to current D, I encounter the following deprecation messages:

Re: DIP 1007 Preliminary Review Round 1

2017-05-10 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 04/25/2017 08:33 AM, Steven Schveighoffer wrote: In the general case, one year is too long. A couple compiler releases should be sufficient. * When the @future attribute is added, would one add it on a dummy symbol or would one provide the implementation as well? dummy symbol. Think of

Re: Problems with Array Assignment?

2017-05-10 Thread Samwise via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 20:01:16 UTC, Adam D. Ruppe wrote: ... Thanks loads. Thanks to this my next commit is going to have quite a few improvements that clean up the engine code considerably. I appreciate the help.

Re: DIP 1007 Preliminary Review Round 1

2017-05-10 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 05/10/2017 11:04 PM, Nick Sabalausky (Abscissa) wrote: On 05/10/2017 09:51 PM, Nick Sabalausky (Abscissa) wrote: This is what FQNs are for. At least, it was before FQNs were broken, first by an incomplete "package.d" system and second by a goofy half-baked change to import rules. FQNs need

Re: "I made a game using Rust"

2017-05-10 Thread rikki cattermole via Digitalmars-d
On 10/05/2017 7:20 PM, zetashift wrote: On Wednesday, 10 May 2017 at 12:52:34 UTC, JN wrote: I wonder, would it be possible for D in the current state to achieve the same? I imagine iOS isn't possible yet and Android is just getting there? Reading this thread while going through the online D

Re: "I made a game using Rust"

2017-05-10 Thread evilrat via Digitalmars-d
On Wednesday, 10 May 2017 at 22:13:29 UTC, Lewis wrote: On Wednesday, 10 May 2017 at 12:52:34 UTC, JN wrote: PROS The Rust article mentions build times as a downside. In contrast, that has been one of the upsides of D for me. My build time is ~1.75s for a usual-case rebuild (all the game

Re: DIP 1007 Preliminary Review Round 1

2017-05-10 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 05/10/2017 09:51 PM, Nick Sabalausky (Abscissa) wrote: This is what FQNs are for. At least, it was before FQNs were broken, first by an incomplete "package.d" system and second by a goofy half-baked change to import rules. FQNs need fixed. This DIP is just a questionable workaround for our

NetBSD amd64: which way is the best for supporting 80 bits real/double?

2017-05-10 Thread Nikolay via Digitalmars-d
I am porting LDC to NetBSD amd64, and I ask advice how to handle real type. NetBSD has limited support for this type. This type exists, but standard library does not provide full set of math functions for it (e.g. sinus, cosinus, and etc). Currently I just forward all function calls to 64 bits

Re: DIP 1007 Preliminary Review Round 1

2017-05-10 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
This is what FQNs are for. At least, it was before FQNs were broken, first by an incomplete "package.d" system and second by a goofy half-baked change to import rules. FQNs need fixed. This DIP is just a questionable workaround for our borked FQNs that that smacks of C++-style "no breakage at

Re: alloca without runtime?

2017-05-10 Thread 岩倉 澪 via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 20:25:45 UTC, aberba wrote: On Thursday, 4 May 2017 at 14:54:58 UTC, 岩倉 澪 wrote: On Thursday, 4 May 2017 at 12:50:02 UTC, Kagamin wrote: You can try ldc and llvm intrinsics http://llvm.org/docs/LangRef.html#alloca-instruction

[Issue 16588] uniq's BidirectionalRange behavior is inconsistent with its InputRange behavior

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16588 greensunn...@gmail.com changed: What|Removed |Added CC||greensunn...@gmail.com --

Re: DIP 1007 Preliminary Review Round 1

2017-05-10 Thread Steven Schveighoffer via Digitalmars-d
On 5/10/17 11:15 AM, Dicebot wrote: On Tuesday, 25 April 2017 at 12:33:44 UTC, Steven Schveighoffer wrote: Actually, that brings up a problem with this, what is the mechanism to say "maybe override"? Let's say you have: // in imported library class Base { void foo() @future; } // in user

Re: "I made a game using Rust"

2017-05-10 Thread H. S. Teoh via Digitalmars-d
On Wed, May 10, 2017 at 07:52:53PM -0400, Steven Schveighoffer via Digitalmars-d wrote: [...] > I'll reiterate here: if the compiler's sanity is suspect, there's nothing > much for it to do except crash. hard. And tell you where to look. [...] OTOH, it's not very nice from a user's POV. It

[Issue 16588] uniq's BidirectionalRange behavior is inconsistent with its InputRange behavior

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16588 hst...@quickfur.ath.cx changed: What|Removed |Added CC||hst...@quickfur.ath.cx --

[Issue 16588] uniq's BidirectionalRange behavior is inconsistent with its InputRange behavior

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16588 Vladimir Panteleev changed: What|Removed |Added Status|RESOLVED|REOPENED

[Issue 17264] [REG2.073] uniq fails with const elements

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17264 --- Comment #3 from github-bugzi...@puremagic.com --- Commit pushed to stable at https://github.com/dlang/phobos https://github.com/dlang/phobos/commit/113502af744fb82d68e8f51fd73831b628dcc1eb std.algorithm.iteration: Add test for issue 17264 Fixes

Re: "I made a game using Rust"

2017-05-10 Thread Steven Schveighoffer via Digitalmars-d
On 5/10/17 10:37 AM, Ethan Watson wrote: On Wednesday, 10 May 2017 at 14:31:28 UTC, Vladimir Panteleev wrote: Internal compiler errors (ICEs) are bugs which are generally treated as high priority. Please report them. See my previous rant on this subject.

Re: Processing a gzipped csv-file by line-by-line

2017-05-10 Thread Jesse Phillips via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 22:20:52 UTC, Nordlöw wrote: What's fastest way to on-the-fly-decompress and process a gzipped csv-fil line by line? Is it possible to combine http://dlang.org/phobos/std_zlib.html with some stream variant of File(path).byLineFast ? You can't really parse a

Re: concepts v0.0.6: use a run-time interface to specify a compile-time one

2017-05-10 Thread Luís Marques via Digitalmars-d-announce
On Wednesday, 10 May 2017 at 10:53:59 UTC, Atila Neves wrote: concepts is a dub package and library that allows one to declare that a struct conforms to a "compile-time interface" such as `isInputRange`. Awesome!

Re: Kafka site needs to be updated with D modules

2017-05-10 Thread Ali Çehreli via Digitalmars-d
Ping... On 04/28/2017 11:36 AM, Ali Çehreli wrote: There are three D modules that I could identify that provide Kafka bindings[1] by searching for "kafka" on the code registry: http://code.dlang.org/ Could people in the know please update the Kafka site with necessary information like what

Re: Processing a gzipped csv-file by line-by-line

2017-05-10 Thread Seb via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 23:19:15 UTC, H. S. Teoh wrote: Also, if you need to parse lots of CSV data very fast, you might be interested in this: https://github.com/quickfur/fastcsv T Or asdf: https://github.com/tamediadigital/asdf

Re: Processing a gzipped csv-file by line-by-line

2017-05-10 Thread H. S. Teoh via Digitalmars-d-learn
On Wed, May 10, 2017 at 11:17:44PM +, Nicholas Wilson via Digitalmars-d-learn wrote: > On Wednesday, 10 May 2017 at 22:20:52 UTC, Nordlöw wrote: > > What's fastest way to on-the-fly-decompress and process a gzipped > > csv-fil line by line? > > > > Is it possible to combine > > > >

Re: Processing a gzipped csv-file by line-by-line

2017-05-10 Thread Nicholas Wilson via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 22:20:52 UTC, Nordlöw wrote: What's fastest way to on-the-fly-decompress and process a gzipped csv-fil line by line? Is it possible to combine http://dlang.org/phobos/std_zlib.html with some stream variant of File(path).byLineFast ? I suggest you take a look

[Issue 17391] SECURITY: XSS through DDOC comments

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17391 --- Comment #7 from Cédric Picard --- (In reply to Vladimir Panteleev from comment #5) > (In reply to Cédric Picard from comment #4) > > Not at all, while what you describe is the most common case there are many > > things

[Issue 16746] Please output Makefile-style depfiles for ninja and make

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16746 --- Comment #13 from Vladimir Panteleev --- (In reply to Matthias Klumpp from comment #12) > Sounds really good, but AFAIK this is still in the far future... > GDC supports writing depfiles properly, and having this feature

[Issue 16746] Please output Makefile-style depfiles for ninja and make

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16746 --- Comment #12 from Matthias Klumpp --- (In reply to Vladimir Panteleev from comment #11) > (In reply to Matthias Klumpp from comment #10) > > Because the wrapper is not available everywhere, and going through a wrapper > >

[Issue 16746] Please output Makefile-style depfiles for ninja and make

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16746 --- Comment #11 from Vladimir Panteleev --- (In reply to Matthias Klumpp from comment #10) > Because the wrapper is not available everywhere, and going through a wrapper > in order to fix a missing thing in dmd is just a

[Issue 16746] Please output Makefile-style depfiles for ninja and make

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16746 --- Comment #10 from Matthias Klumpp --- (In reply to Vladimir Panteleev from comment #9) > (In reply to Matthias Klumpp from comment #8) > > Yes, it doesn't support all command-line flags one would use with ldc, gdc > > or

Re: Processing a gzipped csv-file by line-by-line

2017-05-10 Thread ketmar via Digitalmars-d-learn
Nordlöw wrote: What's fastest way to on-the-fly-decompress and process a gzipped csv-fil line by line? Is it possible to combine http://dlang.org/phobos/std_zlib.html with some stream variant of File(path).byLineFast ? iv.vfs[0] can do that (transparently decompress gzip files, and

Processing a gzipped csv-file by line-by-line

2017-05-10 Thread Nordlöw via Digitalmars-d-learn
What's fastest way to on-the-fly-decompress and process a gzipped csv-fil line by line? Is it possible to combine http://dlang.org/phobos/std_zlib.html with some stream variant of File(path).byLineFast ?

Re: "I made a game using Rust"

2017-05-10 Thread Lewis via Digitalmars-d
On Wednesday, 10 May 2017 at 12:52:34 UTC, JN wrote: I wonder, would it be possible for D in the current state to achieve the same? I imagine iOS isn't possible yet and Android is just getting there? I've been developing a small 2D PC-only game in my free time over the last year or so (10

[Issue 17391] SECURITY: XSS through DDOC comments

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17391 Vladimir Panteleev changed: What|Removed |Added Keywords||pull ---

Re: Error writing file a *.obj

2017-05-10 Thread Stanislav Blinov via Digitalmars-d-learn
On Tuesday, 9 May 2017 at 14:08:48 UTC, bachmeier wrote: On Tuesday, 9 May 2017 at 02:33:06 UTC, dummy wrote: On Monday, 8 May 2017 at 12:29:27 UTC, bachmeier wrote: On Monday, 8 May 2017 at 11:56:10 UTC, dummy wrote: When i build some application with dub, i got this error: I'm not a Dub

[Issue 17391] SECURITY: XSS through DDOC comments

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17391 --- Comment #5 from Vladimir Panteleev --- (In reply to Cédric Picard from comment #4) > Not at all, while what you describe is the most common case there are many > things that are possible through XSS that do not target

Re: How to avoid throwing an exceptions for a built-in function?

2017-05-10 Thread Ali Çehreli via Digitalmars-d-learn
On 05/10/2017 05:40 AM, k-five wrote: > I have a line of code that uses "to" function in std.conv for a purpose > like: > > int index = to!int( user_apply[ 4 ] ); // string to int > > When the user_apply[ 4 ] has value, there is no problem; but when it is > empty: "" > it throws an ConvException

Re: dmd: can't build on Arch Linux or latest Ubuntu

2017-05-10 Thread Seb via Digitalmars-d
On Wednesday, 10 May 2017 at 21:29:24 UTC, Laeeth Isharc wrote: On Wednesday, 10 May 2017 at 16:20:24 UTC, Seb wrote: On Wednesday, 10 May 2017 at 11:51:03 UTC, Atila Neves wrote: I'm using Trusty, and that works. But... it's a matter of time before most people are on newer versions of

[Issue 17391] SECURITY: XSS through DDOC comments

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17391 --- Comment #4 from Cédric Picard --- (In reply to Vladimir Panteleev from comment #3) > As I understand, this only matters from a security standpoint when DDoc > output is placed on the same domain as some dynamic content

Re: How to avoid throwing an exceptions for a built-in function?

2017-05-10 Thread Andrei Alexandrescu via Digitalmars-d-learn
On 5/10/17 3:40 PM, k-five wrote: I have a line of code that uses "to" function in std.conv for a purpose like: int index = to!int( user_apply[ 4 ] ); // string to int When the user_apply[ 4 ] has value, there is no problem; but when it is empty: "" it throws an ConvException exception and

Re: How to avoid throwing an exceptions for a built-in function?

2017-05-10 Thread Moritz Maxeiner via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 21:19:21 UTC, Stanislav Blinov wrote: "nothrow" does not turn off exceptions, it simply forbids throwing them in the enclosing scope (i.e. calling anything that might throw is not allowed). nothrow disallows the function scope to throw exceptions not derived from

Re: Error writing file a *.obj

2017-05-10 Thread Jesse Phillips via Digitalmars-d-learn
On Tuesday, 9 May 2017 at 02:33:06 UTC, dummy wrote: On Monday, 8 May 2017 at 12:29:27 UTC, bachmeier wrote: On Monday, 8 May 2017 at 11:56:10 UTC, dummy wrote: When i build some application with dub, i got this error: I'm not a Dub user, but it has its own forum, so you might want to try

[Issue 17391] SECURITY: XSS through DDOC comments

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17391 --- Comment #3 from Vladimir Panteleev --- (In reply to Cédric Picard from comment #2) > I was not aware that it is so by design. However if it is a design decision > I believe the security consequences should be made very

Re: dmd: can't build on Arch Linux or latest Ubuntu

2017-05-10 Thread Laeeth Isharc via Digitalmars-d
On Wednesday, 10 May 2017 at 16:20:24 UTC, Seb wrote: On Wednesday, 10 May 2017 at 11:51:03 UTC, Atila Neves wrote: I'm using Trusty, and that works. But... it's a matter of time before most people are on newer versions of everything and dmd won't be buildable on Linux. Maybe add newer

Re: dmd: can't build on Arch Linux or latest Ubuntu

2017-05-10 Thread Laeeth Isharc via Digitalmars-d
On Wednesday, 10 May 2017 at 16:20:24 UTC, Seb wrote: On Wednesday, 10 May 2017 at 11:51:03 UTC, Atila Neves wrote: I can't build dmd on Arch Linux anymore. I'm told it's because of a binutils update. Annoying. Yep, at least running the tests on Phobos fails due to changes in binutils 2.28,

Re: dmd: can't build on Arch Linux or latest Ubuntu

2017-05-10 Thread ketmar via Digitalmars-d
Marco Leise wrote: Am Wed, 10 May 2017 20:59:33 +0300 schrieb ketmar : On Wednesday, 10 May 2017 at 11:51:03 UTC, Atila Neves wrote: I can't build dmd on Arch Linux anymore. I'm told it's because of a binutils update. Annoying. yeah, the great thing. i was hit

Re: dmd: can't build on Arch Linux or latest Ubuntu

2017-05-10 Thread Stanislav Blinov via Digitalmars-d
On Wednesday, 10 May 2017 at 21:03:30 UTC, Marco Leise wrote: Am Wed, 10 May 2017 20:59:33 +0300 schrieb ketmar : > On Wednesday, 10 May 2017 at 11:51:03 UTC, Atila Neves wrote: >> I can't build dmd on Arch Linux anymore. I'm told it's >> because of a binutils update.

[Issue 17391] SECURITY: XSS through DDOC comments

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17391 --- Comment #2 from Cédric Picard --- I was not aware that it is so by design. However if it is a design decision I believe the security consequences should be made very explicit and clear in DDOC's documentation so that

Re: How to avoid throwing an exceptions for a built-in function?

2017-05-10 Thread Stanislav Blinov via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 15:35:24 UTC, k-five wrote: On Wednesday, 10 May 2017 at 14:27:46 UTC, Stanislav Blinov wrote: On Wednesday, 10 May 2017 at 13:27:17 UTC, k-five wrote: Thanks, but I know about what are you saying. The user_apply[4] has so many possibilities and I cannot use

[Issue 17391] SECURITY: XSS through DDOC comments

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17391 Vladimir Panteleev changed: What|Removed |Added CC|

Re: dmd: can't build on Arch Linux or latest Ubuntu

2017-05-10 Thread Marco Leise via Digitalmars-d
Am Wed, 10 May 2017 20:59:33 +0300 schrieb ketmar : > > On Wednesday, 10 May 2017 at 11:51:03 UTC, Atila Neves wrote: > >> I can't build dmd on Arch Linux anymore. I'm told it's because of a > >> binutils update. Annoying. > > > yeah, the great thing. i was hit by

[Issue 17391] New: SECURITY: XSS through DDOC comments

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17391 Issue ID: 17391 Summary: SECURITY: XSS through DDOC comments Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: normal Priority:

Re: alloca without runtime?

2017-05-10 Thread aberba via Digitalmars-d-learn
On Thursday, 4 May 2017 at 14:54:58 UTC, 岩倉 澪 wrote: On Thursday, 4 May 2017 at 12:50:02 UTC, Kagamin wrote: You can try ldc and llvm intrinsics http://llvm.org/docs/LangRef.html#alloca-instruction http://llvm.org/docs/LangRef.html#llvm-stacksave-intrinsic Ah, yep! pragma(LDC_alloca) void*

Re: Productive vibe.d dev environment (IDE, debugger) on Linux?

2017-05-10 Thread aberba via Digitalmars-d-learn
On Wednesday, 3 May 2017 at 17:43:07 UTC, kinke wrote: Hey guys, can anyone recommend a more or less production-ready dev environment for vibe.d on Linux? I'm evaluating vibe.d against Phoenix (Elixir/Erlang) for a new project. Today I gave Visual Studio Code a quick shot (with LDC 1.1.1 and

Re: The cost of doing compile time introspection

2017-05-10 Thread Moritz Maxeiner via Digitalmars-d
On Wednesday, 10 May 2017 at 14:03:58 UTC, Biotronic wrote: On Wednesday, 10 May 2017 at 11:45:05 UTC, Moritz Maxeiner wrote: [CTFE slow] First, as you may know, Stefan Koch is working on an improved CTFE engine that will hopefully make things a lot better. As he already pointed out, it

Re: DConf 2017 Hackathon report

2017-05-10 Thread David Nadlinger via Digitalmars-d
On Wednesday, 10 May 2017 at 19:46:01 UTC, Joseph Rushton Wakeling wrote: Ironically, given that I'd always been worried this would be the most finnicky compiler snap to create, it's actually the simplest package definition out of all the Big 3 ;-) Without even having seen your snap file, I

Re: Problems with Array Assignment?

2017-05-10 Thread Adam D. Ruppe via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 17:26:09 UTC, Samwise wrote: I wondered about that when I did it, but I assumed (wrongly) that since the name of the array was the same, it would override it. Nope, this is a somewhat common mistake coming from Python users, but it can't work that way in D since

Re: Fantastic exchange from DConf

2017-05-10 Thread Atila Neves via Digitalmars-d
On Wednesday, 10 May 2017 at 18:58:35 UTC, H. S. Teoh wrote: On Wed, May 10, 2017 at 11:16:57AM +, Atila Neves via Digitalmars-d wrote: [...] [...] Very nice! Reminds me of an incident many years ago where I "optimized" a shell script that took >2 days to generate a report by rewriting

Re: DConf 2017 Hackathon report

2017-05-10 Thread Joseph Rushton Wakeling via Digitalmars-d
On Tuesday, 9 May 2017 at 04:35:40 UTC, Ali Çehreli wrote: Please list what we've achieved during the hackathon, including what is started but is likely to be finished in the coming days or months. Created a working snap package definition for GDC. I'm coordinating with Iain on how to get

Re: Static foreach pull request

2017-05-10 Thread Stefan Koch via Digitalmars-d
On Wednesday, 10 May 2017 at 18:41:30 UTC, Timon Gehr wrote: On 10.05.2017 16:21, Stefan Koch wrote: On Wednesday, 10 May 2017 at 14:13:09 UTC, Timon Gehr wrote: On 10.05.2017 15:18, Stefan Koch wrote: if you try assert([] is null), it should fail. It doesn't. I have tried to make that

Re: Simulating reference variables using `alias this`

2017-05-10 Thread Carl Sturtivant via Digitalmars-d
On Wednesday, 10 May 2017 at 17:48:53 UTC, MrSmith wrote: On Wednesday, 10 May 2017 at 17:12:11 UTC, Carl Sturtivant wrote: Here's the beginning of an interesting little experiment to simulate reference variables using `alias this` to disguise a pointer as a reference. Could add a destructor

Re: Fantastic exchange from DConf

2017-05-10 Thread H. S. Teoh via Digitalmars-d
On Wed, May 10, 2017 at 12:06:46PM +, Patrick Schluter via Digitalmars-d wrote: > On Wednesday, 10 May 2017 at 06:28:31 UTC, H. S. Teoh wrote: > > On Tue, May 09, 2017 at 09:19:08PM -0400, Nick Sabalausky > [...] > > Perhaps I'm just being cynical, but my current unfounded hypothesis > > is

Re: DConf 2017 Hackathon report

2017-05-10 Thread Adrian Matoga via Digitalmars-d
On Tuesday, 9 May 2017 at 13:19:12 UTC, Steven Schveighoffer wrote: But it was very awesome to be able to go around and find the people to discuss a PR/idea without going through a forum thread. I think there's a psychological barrier that happens when you post a complete argument, and then

Re: DConf 2017 Hackathon report

2017-05-10 Thread Adrian Matoga via Digitalmars-d
On Tuesday, 9 May 2017 at 04:35:40 UTC, Ali Çehreli wrote: Please list what we've achieved during the hackathon, including what is started but is likely to be finished in the coming days or months. For me: - Finished updating "Programming in D" to 2.074.0 (the HTML is now up to date but I

Re: Thoughts on some code breakage with 2.074

2017-05-10 Thread Ali Çehreli via Digitalmars-d
On 05/10/2017 11:49 AM, Jonathan M Davis via Digitalmars-d wrote: > On Wednesday, May 10, 2017 05:05:59 Ali Çehreli via Digitalmars-d wrote: >> On 05/09/2017 10:34 AM, H. S. Teoh via Digitalmars-d wrote: >> > After upgrading the compiler, I get a warning that using a pointer as a >> >

Re: Fantastic exchange from DConf

2017-05-10 Thread H. S. Teoh via Digitalmars-d
On Wed, May 10, 2017 at 11:16:57AM +, Atila Neves via Digitalmars-d wrote: [...] > The likelihood of a randomly picked C/C++ programmer not even knowing > what a profiler is, much less having used one, is extremely high in my > experience. I worked with a lot of embedded C programmers with >

Re: Problems with Array Assignment?

2017-05-10 Thread Samwise via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 17:54:38 UTC, Adam D. Ruppe wrote: On Wednesday, 10 May 2017 at 17:47:57 UTC, Samwise wrote: The expected behavior for this is to just see "Different Text" and "Other Text", instead of having any time to see just "Text". However, it seems that the second update

Re: Thoughts on some code breakage with 2.074

2017-05-10 Thread Jonathan M Davis via Digitalmars-d
On Wednesday, May 10, 2017 05:05:59 Ali Çehreli via Digitalmars-d wrote: > On 05/09/2017 10:34 AM, H. S. Teoh via Digitalmars-d wrote: > > I even appreciate breakages that eventually force me to write more > > > > readable code! A not-so-recent example: > >/* Used to work, oh, I forget

Re: Static foreach pull request

2017-05-10 Thread Timon Gehr via Digitalmars-d
On 10.05.2017 16:21, Stefan Koch wrote: On Wednesday, 10 May 2017 at 14:13:09 UTC, Timon Gehr wrote: On 10.05.2017 15:18, Stefan Koch wrote: if you try assert([] is null), it should fail. It doesn't. I have tried to make that point before, unsuccessfully. Empty arrays may or may not be

Re: dmd: can't build on Arch Linux or latest Ubuntu

2017-05-10 Thread Brad Roberts via Digitalmars-d
On 5/10/2017 9:20 AM, Seb via Digitalmars-d wrote: On Wednesday, 10 May 2017 at 11:51:03 UTC, Atila Neves wrote: Maybe add newer distros on the autotester? Hehe, that's nearly not possible. Since a couple of months there's an ongoing effort to change the directory layout to src/ddmd, which

Re: "I made a game using Rust"

2017-05-10 Thread Joakim via Digitalmars-d
On Wednesday, 10 May 2017 at 12:52:34 UTC, JN wrote: Interesting thread I got from Reddit, someone made a game for PC and mobiles fully in Rust. https://michaelfairley.com/blog/i-made-a-game-in-rust/ "Last week, I released A Snake’s Tale on iOS, Android, Windows, Mac, and Linux.". I

Re: Fantastic exchange from DConf

2017-05-10 Thread H. S. Teoh via Digitalmars-d
On Wed, May 10, 2017 at 12:34:05PM +, Guillaume Boucher via Digitalmars-d wrote: [...] > In modern C and with GLib (which makes use of a gcc/clang extension) you can > write this as: > > gboolean myfunc(blah_t *blah, bleh_t *bleh, bluh_t *bluh) { > /* Cleanup everything automatically

Re: "I made a game using Rust"

2017-05-10 Thread zetashift via Digitalmars-d
On Wednesday, 10 May 2017 at 12:52:34 UTC, JN wrote: I wonder, would it be possible for D in the current state to achieve the same? I imagine iOS isn't possible yet and Android is just getting there? Reading this thread while going through the online D book I wonder; Would one recommend D

Re: Fantastic exchange from DConf

2017-05-10 Thread H. S. Teoh via Digitalmars-d
On Wed, May 10, 2017 at 04:38:48AM -0700, Ali Çehreli via Digitalmars-d wrote: > On 05/09/2017 10:26 PM, H. S. Teoh via Digitalmars-d wrote: > > On Wed, May 10, 2017 at 01:32:33AM +, Jack Stouffer via Digitalmars-d > wrote: > >> On Wednesday, 10 May 2017 at 00:30:42 UTC, H. S. Teoh wrote:

Re: dmd: can't build on Arch Linux or latest Ubuntu

2017-05-10 Thread ketmar via Digitalmars-d
Seb wrote: On Wednesday, 10 May 2017 at 11:51:03 UTC, Atila Neves wrote: I can't build dmd on Arch Linux anymore. I'm told it's because of a binutils update. Annoying. Yep, at least running the tests on Phobos fails due to changes in binutils 2.28, see this bug report for more details:

Re: Simulating reference variables using `alias this`

2017-05-10 Thread Carl Sturtivant via Digitalmars-d
On Wednesday, 10 May 2017 at 17:12:11 UTC, Carl Sturtivant wrote: Here's the beginning of an interesting little experiment to simulate reference variables using `alias this` to disguise a pointer as a reference. Could add a destructor to set the pointer to null when a reference goes out of

Re: Problems with Array Assignment?

2017-05-10 Thread Adam D. Ruppe via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 17:47:57 UTC, Samwise wrote: The expected behavior for this is to just see "Different Text" and "Other Text", instead of having any time to see just "Text". However, it seems that the second update method is having the effect that the first call should, and then

Re: Simulating reference variables using `alias this`

2017-05-10 Thread MrSmith via Digitalmars-d
On Wednesday, 10 May 2017 at 17:12:11 UTC, Carl Sturtivant wrote: Here's the beginning of an interesting little experiment to simulate reference variables using `alias this` to disguise a pointer as a reference. Could add a destructor to set the pointer to null when a reference goes out of

Re: Problems with Array Assignment?

2017-05-10 Thread Samwise via Digitalmars-d-learn
I'm also having another problem with this program that is (sorta?) related. If you notice in my main (minus all the comments...), the code creates two tiles, then updates the renderer so that it renders those tiles. Then I create another tile in the same place as one of the first ones (not

[Issue 16746] Please output Makefile-style depfiles for ninja and make

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=16746 --- Comment #9 from Vladimir Panteleev --- (In reply to Matthias Klumpp from comment #8) > Yes, it doesn't support all command-line flags one would use with ldc, gdc > or dmd. rdmd simply forwards flags it doesn't

Re: subtlety or bug?

2017-05-10 Thread Carl Sturtivant via Digitalmars-d-learn
Aha, https://dlang.org/spec/struct.html#struct-destructor says that An identity assignment overload is required for a struct if one or more of these conditions hold: * it has a destructor so this is the above condition coming into play.

Re: Problems with Array Assignment?

2017-05-10 Thread Samwise via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 13:43:54 UTC, Adam D. Ruppe wrote: In your code, I see one big mistake: --- class TileRenderer { private Tile[] tiles; /*...*/ } class CTileRenderer : TileRenderer { private CTile[] tiles; /*...*/ } --- Those are two separate arrays! Stuff examined through

subtlety or bug?

2017-05-10 Thread Carl Sturtivant via Digitalmars-d-learn
The following compiles and runs correctly. https://forum.dlang.org/post/tzwsohkcqrkqotbwn...@forum.dlang.org But if I add a destructor to the reference struct template as follows, it no longer compiles, and the complaints are not about the destructor. ``` ~this() { ptr = null;

Simulating reference variables using `alias this`

2017-05-10 Thread Carl Sturtivant via Digitalmars-d
Here's the beginning of an interesting little experiment to simulate reference variables using `alias this` to disguise a pointer as a reference. Could add a destructor to set the pointer to null when a reference goes out of scope. ``` struct reference(T) { T* ptr; this(ref T x) {

Re: "I made a game using Rust"

2017-05-10 Thread Adam D. Ruppe via Digitalmars-d
On Wednesday, 10 May 2017 at 15:50:06 UTC, Adrian Matoga wrote: In this simple case above, I actually prefer DMD's messages, as there's simply less text for my eyes to read and brain to parse, so I can quickly spot where the problem is. Well, even here, I'd prefer a small tweak: lll.d(6):

Re: Lookahead in unittest

2017-05-10 Thread Raiderium via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 16:32:11 UTC, Adam D. Ruppe wrote: On Wednesday, 10 May 2017 at 16:09:06 UTC, Raiderium wrote: I can't figure out if this is intended behaviour. It is. A unittest is a function, and in functions, all declarations must be defined before used (just like local

Re: Override @property

2017-05-10 Thread Adam D. Ruppe via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 16:40:09 UTC, Aldo wrote: class PictureBox : Control { @property public override void texture(Texture value) { writeln("override"); this.m_texture = value; } } Error: function f340.PictureBox.texture

Override @property

2017-05-10 Thread Aldo via Digitalmars-d-learn
Hello, can you tell me if this compilation error is normal ? class Texture { public this() { } } class Control { private Texture m_texture; @property { public Texture texture() {

Re: Lookahead in unittest

2017-05-10 Thread Adam D. Ruppe via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 16:09:06 UTC, Raiderium wrote: I can't figure out if this is intended behaviour. It is. A unittest is a function, and in functions, all declarations must be defined before used (just like local variables). Sometimes, you can wrap it in a struct: unittest {

Re: "I made a game using Rust"

2017-05-10 Thread Nick Sabalausky (Abscissa) via Digitalmars-d
On 05/10/2017 11:50 AM, Adrian Matoga wrote: On Wednesday, 10 May 2017 at 15:03:19 UTC, Adam D. Ruppe wrote: lll.d(5): Error: function lll.foo (Color c) is not callable using argument types (Color) WTF, right? Well, I have a locally defined `struct Color` and an imported one. Same name, but

Re: dmd: can't build on Arch Linux or latest Ubuntu

2017-05-10 Thread Seb via Digitalmars-d
On Wednesday, 10 May 2017 at 11:51:03 UTC, Atila Neves wrote: I can't build dmd on Arch Linux anymore. I'm told it's because of a binutils update. Annoying. Yep, at least running the tests on Phobos fails due to changes in binutils 2.28, see this bug report for more details:

Re: Lookahead in unittest

2017-05-10 Thread Stefan Koch via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 16:09:06 UTC, Raiderium wrote: Heyo, On 2.074.0, the following test fails with "Error: undefined identifier 'B' " unittest { class A { B b; } class B { } } I can't figure out if this is intended behaviour. It's making a template-heavy module

Lookahead in unittest

2017-05-10 Thread Raiderium via Digitalmars-d-learn
Heyo, On 2.074.0, the following test fails with "Error: undefined identifier 'B' " unittest { class A { B b; } class B { } } I can't figure out if this is intended behaviour. It's making a template-heavy module difficult to test. Would appreciate any help. First post

Re: "I made a game using Rust"

2017-05-10 Thread Adrian Matoga via Digitalmars-d
On Wednesday, 10 May 2017 at 15:03:19 UTC, Adam D. Ruppe wrote: On Wednesday, 10 May 2017 at 14:02:38 UTC, Adrian Matoga wrote: Would you mind giving some examples? What bothers me on a regular basis is overloading. Basic case: $ dmd lll lll.d(6): Error: none of the overloads of 'foo' are

[Issue 14639] Assigning init value to struct uses stack, causing segfault

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=14639 --- Comment #3 from Walter Bright --- The code: biggy = Biggy.init; gets rewritten to be: biggy = Biggy([0LU, ...]); which is a construction. The postblit caused an opAssign() to be created, and the expression

Re: How to avoid throwing an exceptions for a built-in function?

2017-05-10 Thread k-five via Digitalmars-d-learn
On Wednesday, 10 May 2017 at 14:27:46 UTC, Stanislav Blinov wrote: On Wednesday, 10 May 2017 at 13:27:17 UTC, k-five wrote: Thanks, but I know about what are you saying. The user_apply[4] has so many possibilities and I cannot use if-else That doesn't sound right. Either you've already

Re: DConf 2017 Hackathon report

2017-05-10 Thread Joakim via Digitalmars-d
On Tuesday, 9 May 2017 at 17:50:06 UTC, ANtlord wrote: On Tuesday, 9 May 2017 at 04:35:40 UTC, Ali Çehreli wrote: Please list what we've achieved during the hackathon, including what is started but is likely to be finished in the coming days or months. For me: - Finished updating

Re: Mir Algorithm v0.5.8: Interpolation, Timeseries and 17 new functions

2017-05-10 Thread jmh530 via Digitalmars-d-announce
On Wednesday, 10 May 2017 at 11:16:37 UTC, 9il wrote: I have fixed small parts. I have invited you to the Mir Github team. Would be awesome to see your documentation PRs) You can always ask me about implementation details in the Gitter Thanks, Ilya Thanks. Your documentation seems like it

Re: DIP 1007 Preliminary Review Round 1

2017-05-10 Thread Dicebot via Digitalmars-d
On Tuesday, 25 April 2017 at 12:33:44 UTC, Steven Schveighoffer wrote: Actually, that brings up a problem with this, what is the mechanism to say "maybe override"? Let's say you have: // in imported library class Base { void foo() @future; } // in user library class Derived : Base {

Re: "I made a game using Rust"

2017-05-10 Thread Adam D. Ruppe via Digitalmars-d
On Wednesday, 10 May 2017 at 14:02:38 UTC, Adrian Matoga wrote: Would you mind giving some examples? What bothers me on a regular basis is overloading. Basic case: $ dmd lll lll.d(6): Error: none of the overloads of 'foo' are callable using argument types (int, double), candidates are:

[Issue 17390] New: Pass flags to linker driver without -Xlinker

2017-05-10 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=17390 Issue ID: 17390 Summary: Pass flags to linker driver without -Xlinker Product: D Version: D2 Hardware: All OS: Linux Status: NEW Severity: enhancement

  1   2   >