Mercurial > projects > dil
diff trunk/src/dil/Token.d @ 391:33b566df6af4
Migrated project to Tango.
Decremented the numbers of the format placeholders in the localized messages
by one.
Replaced all instances of writef/ln with Stdout.
Added module common.d with string aliases and a global Layout!(char) instance.
Replaced %s format specifiers with index placeholders in html/xml_tags.
Changed member Information.arguments to string message.
Copied std.metastring, std.uni and std.utf from Phobos.
author | Aziz K?ksal <aziz.koeksal@gmail.com> |
---|---|
date | Sat, 15 Sep 2007 17:12:26 +0200 |
parents | 4d36eea1bbc9 |
children | 4d9ee8e60712 |
line wrap: on
line diff
--- a/trunk/src/dil/Token.d Wed Sep 12 21:03:41 2007 +0200 +++ b/trunk/src/dil/Token.d Sat Sep 15 17:12:26 2007 +0200 @@ -3,8 +3,9 @@ License: GPL3 +/ module dil.Token; -import std.c.stdlib : malloc, free; -import std.outofmemory; +import common; +import tango.stdc.stdlib : malloc, free; +import tango.core.Exception; struct Position { @@ -221,10 +222,7 @@ { void* p = malloc(size); if (p is null) - version(Tango) - throw new OutOfMemoryException(__FILE__, __LINE__); - else - throw new OutOfMemoryException(); + throw new OutOfMemoryException(__FILE__, __LINE__); *cast(Token*)p = Token.init; return p; }