Difference between revisions of "Tutorials"
(→How To) |
(→How To) |
||
Line 37: | Line 37: | ||
* [[Using NASM with D]] | * [[Using NASM with D]] | ||
* [[Read table data from file|Split file into multidimensional dynamic string array]] | * [[Read table data from file|Split file into multidimensional dynamic string array]] | ||
− | |||
− | |||
− | |||
* [[Porting 32 Bit Code to 64 Bits]] | * [[Porting 32 Bit Code to 64 Bits]] | ||
* [[Converting C .h Files to D Modules]] | * [[Converting C .h Files to D Modules]] | ||
Line 47: | Line 44: | ||
* [[Extending Unit Tests]] | * [[Extending Unit Tests]] | ||
* [[Running DMD From The Command Prompt]] | * [[Running DMD From The Command Prompt]] | ||
+ | |||
+ | === Microsoft Windows === | ||
+ | * [[D for Win32]] | ||
+ | * [[Win32 DLLs in D]] | ||
+ | * [[COM Programming]] |
Revision as of 11:12, 26 February 2014
Best Practices
- Order of import statements
- Portability and performance
- Conventional module name for importing all modules in a package
Common Idioms
Although D inherited much of its syntax from C and C++, the new features that it introduces lead to some common idioms that are unique to D.
- Initializing variables
- Declaring constants
- Looping over integers
- Unittest placement
- Commenting out code
- Declaring dense multidimensional arrays
- Voldemort types
How To
- Bind D to C
- Compile and link with DMD on Windows
- Link with the Unilink linker on Windows instead of Optlink
- Convert header files with SED
- Define custom print format specifiers
- Function literals
- Implicitly convert a user-defined type to a builtin type
- Output locale character (MBS) to console
- printf
- Promote D Projects
- Regular expressions
- Runtime type information (RTTI)
- Run D in a CGI (web) environment
- Tame OPTLINK
- Run unit tests
- Using NASM with D
- Split file into multidimensional dynamic string array
- Porting 32 Bit Code to 64 Bits
- Converting C .h Files to D Modules
- Instantiating Class Objects Elsewhere Than the GC Heap
- Timing Code
- Using UTF on Windows
- Extending Unit Tests
- Running DMD From The Command Prompt