dmd Questions
2
3
Solved
Here is a simple generator in C#.
IEnumerable<int> Foo()
{
int a = 1, b = 1;
while(true)
{
yield return b;
int temp = a + b;
a = b;
b = temp;
}
}
How do I write a similar genera...
2
Solved
I made a little program in D that computes Fibonacci's numbers. It was supposed to be the most efficient possible, as I did this to compare D's speed of execution to that of other languages. Then I...
Dorrie asked 24/7, 2014 at 15:46
1
Solved
How does std.conv.to!string(enum.member) work? How is it possible that a function takes an enum member and returns its name? Does it use a compiler extension or something similar? It's a bit usual ...
1
Solved
I understand that the align attribute has a few different form of use.
In my first attempt, I was using it as follows:
align(1)
private struct TGAHeader
{
ubyte idLenght;
ubyte hasColormap;
u...
2
How would you develop a library in D language?
I want to write a simple library for image processing that I then want to use in an application.
I am looking for analogy to either Java's JARs with...
1
Solved
I'm trying to implement an instantiator function for my Bound template wrapper but I can't get it to work. I need this in order to convince people at work that we should switch from Ada
to D.
I w...
Chinatown asked 6/7, 2013 at 11:51
2
Solved
I would like to try out D but I'm not quite sure what compiler to use for it. I have found some articles, and also SO questions, on the topic, but I did not find any up-to-date ones.
What are the...
Deathbed asked 16/8, 2013 at 22:6
2
Solved
string reverse(string str) pure nothrow
{
string reverse_impl(string temp, string str) pure nothrow
{
if (str.length == 0)
{
return temp;
}
else
{
return reverse_impl(str[0] ~ temp, str[1....
2
Solved
I am trying to follow examples given in various places for D apps. Generally when learning a language I start on example apps and change them myself, purely to test stuff out.
One app that caught ...
2
1
Solved
2
Solved
Iv been trying to figure this one out forever, and its starting to annoy me. I understand the D runtime library. What it is, what it does. I also understand that you can compile a D app without it....
3
I've tried to statically link with sqlite3 without success. I'm using the 'etc.c.sqlite3' header, and the sqlite3 amalgamation. To create the .lib file I've tried both VC++ and MinGW-gcc, both of t...
1
Solved
I'm having trouble instantiating a RedBlackTree container with chars, but it works with ints:
import std.stdio;
import std.container;
void main()
{
auto r1 = redBlackTree!(int)(); // works
auto...
Mingle asked 8/11, 2012 at 19:2
2
Solved
as easy as it is in other languages, i can't seem to find an option in the d programming language where i can convert a string (ex: "234.32") into a double/float/real.
using atof from the std.c.s...
Supertonic asked 26/9, 2012 at 15:51
1
Solved
I try to compile following code:
import std.algorithm;
void main()
{
string[] x = ["ab", "cd", "ef"]; // 'string' is same as 'immutable(char)[]'
string space = " ";
char z = joiner( x, space )....
5
Solved
I downloaded gtkD-1.5.1 and extracted to some gtkD directory. What do I do next ? I don't understand if I have to compile and link it to some lib or just link to it in my code ?
Edit: (@dsimcha)...
2
Solved
I bought "The D Programming Language" a little while ago. Great book, very educational. However I'm having trouble trying to compile a language feature listed in the book: Extension Functions.
In ...
1
Solved
I'm going insane because I can't make a simple set of triangles appear in my screen.
I'm using OpenGL3 (without the deprecated fixed pipeline) using the derelict bindings for the D programming lan...
4
Solved
How the implementation of the struct in the D language to ubyte [] or ubyte [] to the struct, please brothers help answer this question, thank you!
If a struct contains the string or char [] what ...
3
Solved
What are the Pros/Cons of the different D Compilers? How is the performance and the standard compliance/D2 support? How well are debuggers supported? How good are the Error messages and is the IDE ...
Kinny asked 20/7, 2011 at 19:0
1
I'm trying to install DMDScript-tango on my win32 D1-Tango setup. The version I'm using is the 0.99.9 Kai bundle .
When I try building it, I get the following error (among others)
C:\DMD\sources\...
Worldlywise asked 25/6, 2011 at 9:21
2
Solved
I am new in D and would like to parse a biological file of the form
>name1
acgcgcagagatatagctagatcg
aagctctgctcgcgct
>name2
acgggggcttgctagctcgatagatcga
agctctctttctccttcttcttctagagaga
>n...
1
Solved
I'm in the process of porting, enhancing, and D-atizing our reign SDK from C# to D. Currently working on the Vector2 math module.
Will there be any performance difference between the two structs b...
Indole asked 31/12, 2011 at 9:5
1 Next >
© 2022 - 2024 — McMap. All rights reserved.