Re: [OT?] C compiler written form scratch in D
New videos are comeing soon :) Topics : Intro to compilers Parseing and the AsT Identifier-resolution and scope
Re: Blog: making sure your D projects won't break
On Sunday, 21 December 2014 at 00:14:18 UTC, Joseph Rushton Wakeling wrote: In the longer run, it'd be great if this could become an official part of the D testing framework accessible from dlang.org. It would also be really nice if we could have some sort of link between this system, and the project list on code.dlang.org: perhaps a traffic-light system where a project is marked green if it's compatible with current D release, amber if it works but triggers warnings, and red if it fails? I had that idea in mind for quite some time now, at some point we have been discussing with Sonke what would it take to add such integration. But it is non-trivial effort to get it right and actually useful and I have never had opportunity to spend that much time in a single chunk since then. Thus I decided to go with a more simple non-automated approach for now.
Re: D/Objective-C 64bit
awesome, thank you very much!
Re: C# to D Compiler :)
On Thursday, 18 December 2014 at 23:56:54 UTC, Ronald Adonyo wrote: Hi Everyone, In my spare time over the last 3 weeks, I've been working on a C# to D Compiler based on Roslyn. Please check it out and give comments. I would also like this to be a basis to provide both Libraries in D and allow building native C# applications with the help of D. Its available on my github https://github.com/afrogeek/SharpNative If use the .Net Framework 4.0,it's will better than now,a lot of people will test it,but v4.5.3,maybe a little.
Re: C# to D Compiler :)
One example of a somewhat large performance oriented C# application is OpenRA[1]. (An open-source implementation of the Command Conquer: Red Alert engine using .NET/Mono and OpenGL. Runs on Windows, Linux and Mac OS X) It is interesting to see how far it can be translated from C# to D and what the performance would be. I'll give it a shot when I have the time, though you may also find it useful as a way to benchmark your compiler ;) [1]: https://github.com/OpenRA/OpenRA
Re: 2D game engine written in D is in progress
On Sun, 21 Dec 2014 07:54:53 + Joakim via Digitalmars-d-announce digitalmars-d-announce@puremagic.com wrote: On Saturday, 20 December 2014 at 18:49:06 UTC, ketmar via Digitalmars-d-announce wrote: On Sat, 20 Dec 2014 17:12:46 + Joakim via Digitalmars-d-announce digitalmars-d-announce@puremagic.com wrote: Why would we collect stats: what difference does it make if an OSS project is 10% commercially developed or 20%? 'cause i want to know what much more means. 1? 10? 100? 1000? 1? sure, 1 is much more than zero, as 1 is not nothing. but how much? There are patches being sent upstream that would not be sent otherwise, that's all that matters. nope. when i see much more, i want to know how much is that much. That still doesn't answer the question of why anyone would spend time collecting stats when it's pointless to quantify anyway. If it's 20%, is it all of a sudden worth it for you? 10%? 30%? i believe that when someone says much more, he didn't take the numbers from /dev/urandom, and he already has very impressive stats. why else he would do comparisons? he must base his opinion on some numbers. or... or i just can say that with my contributions Linux got many more patches, so prise me -- and everyone will believe? i bet not, i will be asked for at least numerical proofs. so i won't buy bs about many more patches with android without numbers at least. and then i will ask to show *what* parts was changed, just to make sure that this is not a useless android-specific crap. see, m$ recently commits alot of patches, yet it's still very hard to say that microsoft help develops Linux. what those patches do is compatibility with their proprietary hyperv. useless crap. yet numbers still looks impressive. You may not care about any of these patches for your own use, because you don't use ARM or whatever, but you certainly seem to care about FOSS doing well. i still can't understand what doing well means. what i see is that with corporations comes a rise of permissive licenses, and i can't see that as good thing. I've explained in detail what doing well means: these hobbyist OSS projects, whether the linux kernel or gcc or whatever you prefer, would be unusable for any real work without significant commercial involvement over the years. Not sure what's difficult to understand about that. you didn't give any proofs. moreover, you simply lying, as gcc, for example, was perfectly usable long before commercial vendors starts sending patches. and i can assure you that Linux and GCC are not the only [F]OSS projects which are very usable for real work (i don't know what real work and unreal work is, but hell with it). It's not just corporations using permissive licenses. Many more individuals choose a permissive license for their personal projects these days, as opposed to emulating linux and choosing the GPL by default like they did in the past. ah, so you saying that they specifically don't want to emulate Linux success? i knew that! from my POV the only sane reason why author can choose permissive license is to steal my code. so he can take my contribution, use it in proprietary closed-source version and make money from it. i see nothing bad from making money from the product... until that product uses my code in the way that i can't get free access to product sources AND i can't pass those sources around freely. oh, i mean the code i wrote without payment. and i prefer GPLv3 over GPLv2 as GPLv3 closes tivoisation hole. Well, the only reason FOSS suits your needs and has any usage today is precisely because commercial vendors contributed greatly to its development i don't think so. OpenBSD suits too. it just happens that i didn't have an access to *BSD at the time, so i took Linux. yet i'm seriously thinking about dropping Linux, as with all those commercial support is suits me lesser and lesser. You think OpenBSD did not also benefit from commercial help? if you'll go this way you'll found that nobody using hand-made computers for running FOSS software, so... i want numbers. again. and proofs that without such help the project will be in unusable state now. i don't know how you can make such proofs, but that's not me who claims that without commercial proof FOSS is not ready for real work, so it's not me who must give proofs. i'm telling you that... let's take emacs and GCC: emacs, GCC and GDB was perfectly usable before corporations started to take FOSS movement seriously. you know what... the whole UNIX story started as guerilla OS. only when UNIX becames successfull, AT/T begins to invest money in it. and, btw, did that completely wrong, effectively killed UNIX. The viral GPL may have helped linux initially, when it was mostly consulting/support companies like IBM and Red Hat using open source, so the viral aspect of forcing them to release source pushed linux ahead of
Re: C# to D Compiler :)
On Sunday, 21 December 2014 at 15:12:26 UTC, ZombineDev wrote: One example of a somewhat large performance oriented C# application is OpenRA[1]. (An open-source implementation of the Command Conquer: Red Alert engine using .NET/Mono and OpenGL. Runs on Windows, Linux and Mac OS X) It is interesting to see how far it can be translated from C# to D and what the performance would be. I'll give it a shot when I have the time, though you may also find it useful as a way to benchmark your compiler ;) [1]: https://github.com/OpenRA/OpenRA Last time (long ago) I looked at OpenRA code it didn't look like its source would (directly) translate well to high-performance D/C++/whatever. You'd end up needing to turn some structs to classes, limit GC usage (.NET has a much better GC, yet non-GC code is simpler in D), etc. (I'm planning to work on a project with similar goals to OpenRA, although for academic reasons I'm still only working on its entity system (https://github.com/kiith-sa/tharsis-core).
Re: 2D game engine written in D is in progress
On Sunday, 21 December 2014 at 15:44:05 UTC, ketmar via Digitalmars-d-announce wrote: On Sun, 21 Dec 2014 07:54:53 + Joakim via Digitalmars-d-announce digitalmars-d-announce@puremagic.com wrote: That still doesn't answer the question of why anyone would spend time collecting stats when it's pointless to quantify anyway. If it's 20%, is it all of a sudden worth it for you? 10%? 30%? i believe that when someone says much more, he didn't take the numbers from /dev/urandom, and he already has very impressive stats. why else he would do comparisons? he must base his opinion on some numbers. or... or i just can say that with my contributions Linux got many more patches, so prise me -- and everyone will believe? i bet not, i will be asked for at least numerical proofs. so i won't buy bs about many more patches with android without numbers at least. and then i will ask to show *what* parts was changed, just to make sure that this is not a useless android-specific crap. But nobody cares to prove it to you. I made an assertion that patches were upstreamed, all the raw data is out there to show that. If you're unwilling to go look for it, doesn't bother me. see, m$ recently commits alot of patches, yet it's still very hard to say that microsoft help develops Linux. what those patches do is compatibility with their proprietary hyperv. useless crap. yet numbers still looks impressive. Except that Android obviously has nothing so narrow as Hyper-V to which it's isolated to. I've explained in detail what doing well means: these hobbyist OSS projects, whether the linux kernel or gcc or whatever you prefer, would be unusable for any real work without significant commercial involvement over the years. Not sure what's difficult to understand about that. you didn't give any proofs. moreover, you simply lying, as gcc, for example, was perfectly usable long before commercial vendors starts sending patches. and i can assure you that Linux and GCC are not the only [F]OSS projects which are very usable for real work (i don't know what real work and unreal work is, but hell with it). What would be proofs of being made much more viable by commercial involvement? As for linux and gcc not being the only mature projects, every other one you can think of very likely also benefited greatly from commercial investment. It's not just corporations using permissive licenses. Many more individuals choose a permissive license for their personal projects these days, as opposed to emulating linux and choosing the GPL by default like they did in the past. ah, so you saying that they specifically don't want to emulate Linux success? i knew that! Yep, they'd rather be _much_ more successful, like Android or llvm. :D from my POV the only sane reason why author can choose permissive license is to steal my code. so he can take my contribution, use it in proprietary closed-source version and make money from it. If he's the author, how is he stealing your code? Google runs a patched linux kernel on a million servers and mostly doesn't release their patches, did they steal code from all linux kernel contributors? i see nothing bad from making money from the product... until that product uses my code in the way that i can't get free access to product sources AND i can't pass those sources around freely. oh, i mean the code i wrote without payment. You always have access to your code, just not necessarily to code others wrote on top of your code. and i prefer GPLv3 over GPLv2 as GPLv3 closes tivoisation hole. Yes, you mentioned that before. You think OpenBSD did not also benefit from commercial help? if you'll go this way you'll found that nobody using hand-made computers for running FOSS software, so... i want numbers. again. and proofs that without such help the project will be in unusable state now. i don't know how you can make such proofs, but that's not me who claims that without commercial proof FOSS is not ready for real work, so it's not me who must give proofs. i'm telling you that... let's take emacs and GCC: emacs, GCC and GDB was perfectly usable before corporations started to take FOSS movement seriously. I see, you want proofs, but don't know how you can make such proofs. Awfully convenient to demand proof and not define what you'll accept as proof. As I said before, all the data is out there, you're free to prove it to yourself. you know what... the whole UNIX story started as guerilla OS. only when UNIX becames successfull, AT/T begins to invest money in it. and, btw, did that completely wrong, effectively killed UNIX. This is commonly the case, doesn't matter if it's OSS or not. The viral GPL may have helped linux initially, when it was mostly consulting/support companies like IBM and Red Hat using open source, so the viral aspect of forcing them to release source pushed linux ahead of BSD. But now that companies are more
Re: 2D game engine written in D is in progress
On Sun, 21 Dec 2014 18:24:12 + Joakim via Digitalmars-d-announce digitalmars-d-announce@puremagic.com wrote: But nobody cares to prove it to you. I made an assertion that patches were upstreamed, all the raw data is out there to show that. If you're unwilling to go look for it, doesn't bother me. do you see how discussion without proofs has no sense at all? It's not just corporations using permissive licenses. Many more individuals choose a permissive license for their personal projects these days, as opposed to emulating linux and choosing the GPL by default like they did in the past. ah, so you saying that they specifically don't want to emulate Linux success? i knew that! Yep, they'd rather be _much_ more successful, like Android or llvm. :D individial projects. android. llvm. you just divided by zero. from my POV the only sane reason why author can choose permissive license is to steal my code. so he can take my contribution, use it in proprietary closed-source version and make money from it. If he's the author, how is he stealing your code? i obviously meant he accepted my patches, and then... Google runs a patched linux kernel on a million servers and mostly doesn't release their patches, did they steal code from all linux kernel contributors? does google selling that servers with patched kernel? i was talking about selling the software product (as a standalone product or with accompanying hardware). using the product in-house to built some system whose output then sold is ok. i see nothing bad from making money from the product... until that product uses my code in the way that i can't get free access to product sources AND i can't pass those sources around freely. oh, i mean the code i wrote without payment. You always have access to your code, just not necessarily to code others wrote on top of your code. and that is wrong. either not use my code at all, or give me all the code that is using my code, with rights to redistribute. I see, you want proofs, but don't know how you can make such proofs. Awfully convenient to demand proof and not define what you'll accept as proof. that wasn't me who created such situation. As I said before, all the data is out there, you're free to prove it to yourself. so you have no proofs. q.e.d. you know what... the whole UNIX story started as guerilla OS. only when UNIX becames successfull, AT/T begins to invest money in it. and, btw, did that completely wrong, effectively killed UNIX. This is commonly the case, doesn't matter if it's OSS or not. and that kills the whole your argument about OSS software can't be grown to use in 'real work' without corporate support. why do you think that i should care how much money corporations will get? i know that most people don't give a shit about their freedom and would sell it for a dime. I already explained why: because that means they put more money into permissively-licensed projects like AOSP, clang/llvm, etc. the projects for which i see no use. i just can't care less. Stallman accidentally got some things right no, that wasn't accidentally. he is *always* right. and each time RL goes by Stallman, people keep telling me that this was an accident and pure luck(unluck). won't buy it. That's why the GPL is dying off. but it isn't. corporate players trying to establish their rules and subvert FOSS definition, this is true. but what they actually doing is just preparing another rise of FOSS and GPL. people need some time to grok that permissive licenses are used to took away people's freedom, and then everything will start all over again. I don't see how they're doing anything to you this is the root of the whole problem. Anyway, you seem ideologically committed to the GPL, no matter how flawed it is, so I'll leave it here. not to GPL itself, but to freedom. for now the best tool we have to protect our freedom in software industry is GPL. but i really don't care about tools much, i care for the purpose for which those tools were designed. signature.asc Description: PGP signature
Re: 2D game engine written in D is in progress
Sigh, I did ask you some questions, which you've answered with a couple more questions, so I'll give you one last response. On Sunday, 21 December 2014 at 18:52:00 UTC, ketmar via Digitalmars-d-announce wrote: On Sun, 21 Dec 2014 18:24:12 + Joakim via Digitalmars-d-announce digitalmars-d-announce@puremagic.com wrote: But nobody cares to prove it to you. I made an assertion that patches were upstreamed, all the raw data is out there to show that. If you're unwilling to go look for it, doesn't bother me. do you see how discussion without proofs has no sense at all? No, I see that you asking me to quantify something and then dodging the question of why it should be quantified, ie when I asked you what your magical threshold of relevance is, makes no sense at all. :) In any case, whatever you think that would prove, I have not offered to prove it to you. The raw data is out there: if you want certain statistics extracted from that data that only matter to you, it's up to you to collect them. ah, so you saying that they specifically don't want to emulate Linux success? i knew that! Yep, they'd rather be _much_ more successful, like Android or llvm. :D individial projects. android. llvm. you just divided by zero. Whatever that means. Both have become much more successful in recent years by using mostly permissive licenses. from my POV the only sane reason why author can choose permissive license is to steal my code. so he can take my contribution, use it in proprietary closed-source version and make money from it. If he's the author, how is he stealing your code? i obviously meant he accepted my patches, and then... If you sent him patches, he's not stealing your code. No wonder you left that part out, but your whole story made no sense without it. Google runs a patched linux kernel on a million servers and mostly doesn't release their patches, did they steal code from all linux kernel contributors? does google selling that servers with patched kernel? i was talking about selling the software product (as a standalone product or with accompanying hardware). using the product in-house to built some system whose output then sold is ok. I see, so it's okay if google takes outside patches for their kernel, creates a search engine on top of it, and then sells access to the advertising on that search engine without releasing any kernel source, but not okay if they sell those same servers with that patched kernel and search engine bundled without including any kernel source. This is the classic idiocy of GPL zealots, where they imagine they are purists for freedom then twist themselves in knots when it's pointed out the GPL actually doesn't accomplish that in any meaningful way, since most GPL code actually runs on the server. Of course, some then go use the AGPL, but that's a small minority. i see nothing bad from making money from the product... until that product uses my code in the way that i can't get free access to product sources AND i can't pass those sources around freely. oh, i mean the code i wrote without payment. You always have access to your code, just not necessarily to code others wrote on top of your code. and that is wrong. either not use my code at all, or give me all the code that is using my code, with rights to redistribute. Funny how you don't make the same demands of google or some other cloud vendor who runs your code. I guess distribution must be magical somehow, ie it's okay if they run your code on the server, just not on the desktop. I see, you want proofs, but don't know how you can make such proofs. Awfully convenient to demand proof and not define what you'll accept as proof. that wasn't me who created such situation. As I said before, all the data is out there, you're free to prove it to yourself. so you have no proofs. q.e.d. Lol, _you_ created the impossible situation of demanding proof you couldn't define, nobody is going to prove it to you. you know what... the whole UNIX story started as guerilla OS. only when UNIX becames successfull, AT/T begins to invest money in it. and, btw, did that completely wrong, effectively killed UNIX. This is commonly the case, doesn't matter if it's OSS or not. and that kills the whole your argument about OSS software can't be grown to use in 'real work' without corporate support. I was only agreeing that anything successful usually starts as guerilla and that when a large company starts investing a lot in it, they often make mistakes. No idea how you draw the conclusion from that that OSS can't be made more viable through corporate support, especially given that that has been shown invariably to be the case. why do you think that i should care how much money corporations will get? i know that most people don't give a shit about their freedom and would sell it for a dime. I already explained why: because that
HDF5 bindings for D
https://github.com/Laeeth/d_hdf5 HDF5 is a very valuable tool for those working with large data sets. From HDF5group.org HDF5 is a unique technology suite that makes possible the management of extremely large and complex data collections. The HDF5 technology suite includes: * A versatile data model that can represent very complex data objects and a wide variety of metadata. * A completely portable file format with no limit on the number or size of data objects in the collection. * A software library that runs on a range of computational platforms, from laptops to massively parallel systems, and implements a high-level API with C, C++, Fortran 90, and Java interfaces. * A rich set of integrated performance features that allow for access time and storage space optimizations. * Tools and applications for managing, manipulating, viewing, and analyzing the data in the collection. * The HDF5 data model, file format, API, library, and tools are open and distributed without charge. From h5py.org: [HDF5] lets you store huge amounts of numerical data, and easily manipulate that data from NumPy. For example, you can slice into multi-terabyte datasets stored on disk, as if they were real NumPy arrays. Thousands of datasets can be stored in a single file, categorized and tagged however you want. H5py uses straightforward NumPy and Python metaphors, like dictionary and NumPy array syntax. For example, you can iterate over datasets in a file, or check out the .shape or .dtype attributes of datasets. You don't need to know anything special about HDF5 to get started. In addition to the easy-to-use high level interface, h5py rests on a object-oriented Cython wrapping of the HDF5 C API. Almost anything you can do from C in HDF5, you can do from h5py. Best of all, the files you create are in a widely-used standard binary format, which you can exchange with other people, including those who use programs like IDL and MATLAB. === As far as I know there has not really been a complete set of HDF5 bindings for D yet. Bindings should have three levels: 1. pure C API declaration 2. 'nice' D wrapper around C API (eg that knows about strings, not just char*) 3. idiomatic D interface that uses CTFE/templates I borrowed Stefan Frijter's work on (1) above to get started. I cannot keep track of things when split over too many source files, so I put everything in one file - hdf5.d. Have implemented a basic version of 2. Includes throwOnError rather than forcing checking status C style, but the exception code is not very good/complete (time + lack of experience with D exceptions). (3) will have to come later. It's more or less complete, and the examples I have translated so far mostly work. But still a work in progress. Any help/suggestions appreciated. [I am doing this for myself, so project is not as pretty as I would like in an ideal world]. https://github.com/Laeeth/d_hdf5
Re: HDF5 bindings for D
On 22/12/2014 5:51 p.m., Laeeth Isharc wrote: https://github.com/Laeeth/d_hdf5 HDF5 is a very valuable tool for those working with large data sets. From HDF5group.org HDF5 is a unique technology suite that makes possible the management of extremely large and complex data collections. The HDF5 technology suite includes: * A versatile data model that can represent very complex data objects and a wide variety of metadata. * A completely portable file format with no limit on the number or size of data objects in the collection. * A software library that runs on a range of computational platforms, from laptops to massively parallel systems, and implements a high-level API with C, C++, Fortran 90, and Java interfaces. * A rich set of integrated performance features that allow for access time and storage space optimizations. * Tools and applications for managing, manipulating, viewing, and analyzing the data in the collection. * The HDF5 data model, file format, API, library, and tools are open and distributed without charge. From h5py.org: [HDF5] lets you store huge amounts of numerical data, and easily manipulate that data from NumPy. For example, you can slice into multi-terabyte datasets stored on disk, as if they were real NumPy arrays. Thousands of datasets can be stored in a single file, categorized and tagged however you want. H5py uses straightforward NumPy and Python metaphors, like dictionary and NumPy array syntax. For example, you can iterate over datasets in a file, or check out the .shape or .dtype attributes of datasets. You don't need to know anything special about HDF5 to get started. In addition to the easy-to-use high level interface, h5py rests on a object-oriented Cython wrapping of the HDF5 C API. Almost anything you can do from C in HDF5, you can do from h5py. Best of all, the files you create are in a widely-used standard binary format, which you can exchange with other people, including those who use programs like IDL and MATLAB. === As far as I know there has not really been a complete set of HDF5 bindings for D yet. Bindings should have three levels: 1. pure C API declaration 2. 'nice' D wrapper around C API (eg that knows about strings, not just char*) 3. idiomatic D interface that uses CTFE/templates I borrowed Stefan Frijter's work on (1) above to get started. I cannot keep track of things when split over too many source files, so I put everything in one file - hdf5.d. Have implemented a basic version of 2. Includes throwOnError rather than forcing checking status C style, but the exception code is not very good/complete (time + lack of experience with D exceptions). (3) will have to come later. It's more or less complete, and the examples I have translated so far mostly work. But still a work in progress. Any help/suggestions appreciated. [I am doing this for myself, so project is not as pretty as I would like in an ideal world]. https://github.com/Laeeth/d_hdf5 You seem to be missing your dub file. Would be rather hard to get it onto dub repository without it ;) Oh and keep the bindings separate from wrappers in terms of subpackages.