Re: Package and virtual functions

2012-06-13 Thread Jonathan M Davis
On Thursday, June 14, 2012 08:30:26 Jacob Carlborg wrote: > On 2012-06-14 00:48, Jonathan M Davis wrote: > > On Thursday, June 14, 2012 00:32:45 BLM768 wrote: > >> For some reason, whenever I declare a method with package > >> visibility, it becomes non-virtual. Is this normal behavior, or > >> is

Re: Package and virtual functions

2012-06-13 Thread Jacob Carlborg
On 2012-06-14 00:48, Jonathan M Davis wrote: On Thursday, June 14, 2012 00:32:45 BLM768 wrote: For some reason, whenever I declare a method with package visibility, it becomes non-virtual. Is this normal behavior, or is there a bug in DMD 2.059? Only public and protected functions can be virtu

Re: Idea: writeln and file functions that return the data passed to them

2012-06-13 Thread Simen Kjaeraas
On Tue, 12 Jun 2012 14:12:19 +0200, ixid wrote: Perhaps there is already a way to do this. With the UFCS one tends to make elegant chains of statements, it would be useful to have writeln and file functions that can easily be dropped in the middle of such chains without having to alter the

Re: align(16) struct member throws an exception with movdqa

2012-06-13 Thread Jonathan M Davis
On Thursday, June 14, 2012 00:17:25 Sean Cavanaugh wrote: > On 6/11/2012 7:15 AM, Trass3r wrote: > >> I think it has been fixed for the next version of DMD already. Any > >> idea why align isn't letting me use movdqa? > > > > Cause align doesn't work the way you think it does. > > In fact I still

Re: align(16) struct member throws an exception with movdqa

2012-06-13 Thread Sean Cavanaugh
On 6/11/2012 7:15 AM, Trass3r wrote: I think it has been fixed for the next version of DMD already. Any idea why align isn't letting me use movdqa? Cause align doesn't work the way you think it does. In fact I still don't understand how it works at all. The language align keyword can only red

Re: Package and virtual functions

2012-06-13 Thread Timon Gehr
On 06/14/2012 01:57 AM, BLM768 wrote: I guess that another solution to this whole mess is to just start requiring the use of override; then everyone would be educated and it would be obvious where the bug is in the code I posted. Since we don't want to break code, though, maybe there should be a

Re: Package and virtual functions

2012-06-13 Thread BLM768
I guess that another solution to this whole mess is to just start requiring the use of override; then everyone would be educated and it would be obvious where the bug is in the code I posted. Since we don't want to break code, though, maybe there should be a message prominently displayed on the

Re: Package and virtual functions

2012-06-13 Thread BLM768
True, but it will be explicit in the derived class code: No 'override', no function that is overridden. However, if a programmer expects it to override, there could be an issue. Imagine a novice D programmer who is not used to using "override" and looks at at the following code: class Bas

Re: Package and virtual functions

2012-06-13 Thread Jonathan M Davis
On Thursday, June 14, 2012 01:34:42 BLM768 wrote: > > override will eventually be required when overriding a > > function. It is already > > if you compile with -w but not yet all of the time - though > > since protected > > isn't virtual and isn't really overriding anything, the > > compiler doesn

Re: Package and virtual functions

2012-06-13 Thread Timon Gehr
On 06/14/2012 01:34 AM, BLM768 wrote: override will eventually be required when overriding a function. It is already if you compile with -w but not yet all of the time - though since protected isn't virtual and isn't really overriding anything, the compiler doesn't complain if you don't use ov

Re: Package and virtual functions

2012-06-13 Thread BLM768
override will eventually be required when overriding a function. It is already if you compile with -w but not yet all of the time - though since protected isn't virtual and isn't really overriding anything, the compiler doesn't complain if you don't use override with it (though it will if y

Re: Package and virtual functions

2012-06-13 Thread Jonathan M Davis
On Thursday, June 14, 2012 01:07:17 BLM768 wrote: > On Wednesday, 13 June 2012 at 22:48:34 UTC, Jonathan M Davis > > wrote: > > On Thursday, June 14, 2012 00:32:45 BLM768 wrote: > >> For some reason, whenever I declare a method with package > >> visibility, it becomes non-virtual. Is this normal b

Re: Package and virtual functions

2012-06-13 Thread BLM768
On Wednesday, 13 June 2012 at 22:48:34 UTC, Jonathan M Davis wrote: On Thursday, June 14, 2012 00:32:45 BLM768 wrote: For some reason, whenever I declare a method with package visibility, it becomes non-virtual. Is this normal behavior, or is there a bug in DMD 2.059? Only public and protected

Re: Package and virtual functions

2012-06-13 Thread Jonathan M Davis
On Thursday, June 14, 2012 00:32:45 BLM768 wrote: > For some reason, whenever I declare a method with package > visibility, it becomes non-virtual. Is this normal behavior, or > is there a bug in DMD 2.059? Only public and protected functions can be virtual. private and package functions are neve

Package and virtual functions

2012-06-13 Thread BLM768
For some reason, whenever I declare a method with package visibility, it becomes non-virtual. Is this normal behavior, or is there a bug in DMD 2.059?

Re: Does D have high-performance sockets

2012-06-13 Thread D Day
On Wednesday, 13 June 2012 at 17:21:15 UTC, Dejan Lekic wrote: On Wednesday, 13 June 2012 at 15:53:15 UTC, Jarl André wrote: On Wednesday, 13 June 2012 at 10:24:58 UTC, Dmitry Olshansky wrote: On 13.06.2012 1:29, D Day wrote: Are there any implementations of this anywhere for D? I really only

Re: Does D have high-performance sockets

2012-06-13 Thread Dejan Lekic
On Wednesday, 13 June 2012 at 15:53:15 UTC, Jarl André wrote: On Wednesday, 13 June 2012 at 10:24:58 UTC, Dmitry Olshansky wrote: On 13.06.2012 1:29, D Day wrote: Are there any implementations of this anywhere for D? I really only care about the windows platform - and have considered writing

Re: What exact GDB version has decent native D support?

2012-06-13 Thread Jonathan M Davis
On Wednesday, June 13, 2012 19:06:29 Alex Rønne Petersen wrote: > Hi, > > Since what GDB version does decent support for the D DWARF extensions exist? IIRC, you need at least gdb 7.2. - Jonathan M Davis

What exact GDB version has decent native D support?

2012-06-13 Thread Alex Rønne Petersen
Hi, Since what GDB version does decent support for the D DWARF extensions exist? -- Alex Rønne Petersen a...@lycus.org http://lycus.org

Re: Does D have high-performance sockets

2012-06-13 Thread Jarl André
On Wednesday, 13 June 2012 at 10:24:58 UTC, Dmitry Olshansky wrote: On 13.06.2012 1:29, D Day wrote: Are there any implementations of this anywhere for D? I really only care about the windows platform - and have considered writing this myself with IOCP and std.socket, but I figure someone els

Re: Code-File structure

2012-06-13 Thread Kagamin
On Wednesday, 13 June 2012 at 15:15:11 UTC, Kagamin wrote: On Tuesday, 12 June 2012 at 19:35:47 UTC, Henrik Valter Vogelius Hansson wrote: Nice thanks! That will help me out a lot! Is there a "D" way to do it? Or is D too young to have that yet? The D way is to have all classes in one file.

Re: Code-File structure

2012-06-13 Thread Kagamin
On Tuesday, 12 June 2012 at 19:35:47 UTC, Henrik Valter Vogelius Hansson wrote: Nice thanks! That will help me out a lot! Is there a "D" way to do it? Or is D too young to have that yet? The D way is to have all classes in one file.

Re: DMD can't link opengl32.lib

2012-06-13 Thread Kagamin
On Wednesday, 13 June 2012 at 13:03:04 UTC, Zhenya wrote: When I wanted to use native opengl binding module main; import std.stdio; import c.gl.gl; pragma(lib,"opengl32.lib"); import c.gl.glu; pragma(lib,"glu32.lib"); int main(string[] argv) { writeln("Hello D-World!"); return 0; } DM

Re: Is D actually |-----------this-----powerful-----------|?

2012-06-13 Thread Kagamin
On Saturday, 9 June 2012 at 17:07:19 UTC, David Piepgrass wrote: auto mass = kg(2.0); auto accel = 1.0; auto force = mass*accel; accel += metresPerSecondSquared(9.81); // units of 'force' and 'accel' now known force += pounds(3.0); // unit mismatch detected accel will be doub

Re: DMD can't link opengl32.lib

2012-06-13 Thread Zhenya
On Wednesday, 13 June 2012 at 14:05:46 UTC, Denis Shelomovskij wrote: 13.06.2012 17:53, Zhenya пишет: Те которые с DMC идут он проглотит Да. В FAQ есть ссылка на coff2omf, но он проприетарный. Может помочь coffimplib: http://www.digitalmars.com/ctg/coffimplib.html ftp://ftp.digitalmars.com/c

Re: DMD can't link opengl32.lib

2012-06-13 Thread Denis Shelomovskij
13.06.2012 17:53, Zhenya пишет: Те которые с DMC идут он проглотит Да. В FAQ есть ссылка на coff2omf, но он проприетарный. Может помочь coffimplib: http://www.digitalmars.com/ctg/coffimplib.html ftp://ftp.digitalmars.com/coffimplib.zip -- Денис В. Шеломовский Denis V. Shelomovskij

Re: DMD can't link opengl32.lib

2012-06-13 Thread Zhenya
On Wednesday, 13 June 2012 at 13:44:51 UTC, Zhenya wrote: On Wednesday, 13 June 2012 at 13:16:20 UTC, Denis Shelomovskij wrote: 13.06.2012 17:03, Zhenya пишет: When I wanted to use native opengl binding ... DMD wrote:opengl32.lib Error 43: Not a Valid Library File But why can't dmd link it?

Re: DMD can't link opengl32.lib

2012-06-13 Thread Zhenya
On Wednesday, 13 June 2012 at 13:16:20 UTC, Denis Shelomovskij wrote: 13.06.2012 17:03, Zhenya пишет: When I wanted to use native opengl binding ... DMD wrote:opengl32.lib Error 43: Not a Valid Library File But why can't dmd link it? http://dlang.org/faq.html#omf Cпасибо=) А не подскажеш

Re: DMD can't link opengl32.lib

2012-06-13 Thread Denis Shelomovskij
13.06.2012 17:03, Zhenya пишет: When I wanted to use native opengl binding ... DMD wrote:opengl32.lib Error 43: Not a Valid Library File But why can't dmd link it? http://dlang.org/faq.html#omf -- Денис В. Шеломовский Denis V. Shelomovskij

DMD can't link opengl32.lib

2012-06-13 Thread Zhenya
When I wanted to use native opengl binding module main; import std.stdio; import c.gl.gl; pragma(lib,"opengl32.lib"); import c.gl.glu; pragma(lib,"glu32.lib"); int main(string[] argv) { writeln("Hello D-World!"); return 0; } DMD wrote:opengl32.lib Error 43: Not a Valid Library File B

Re: Does D have high-performance sockets

2012-06-13 Thread Dmitry Olshansky
On 13.06.2012 1:29, D Day wrote: Are there any implementations of this anywhere for D? I really only care about the windows platform - and have considered writing this myself with IOCP and std.socket, but I figure someone else must have already done something similar? Take a look at vibe.d. Wh

Re: Does D have high-performance sockets

2012-06-13 Thread Regan Heath
On Tue, 12 Jun 2012 22:29:58 +0100, D Day wrote: Are there any implementations of this anywhere for D? I really only care about the windows platform - and have considered writing this myself with IOCP and std.socket, but I figure someone else must have already done something similar? Not