delete and MmFile

2012-01-28 Thread NewName
Hello everybody. So I heard that `delete' is being deprecated? If that's true, what can I do to close an MmFile? Or is there another way to create an MmFile object, other than with `new', so that it gets destroyed when out of scope? My problem is, I need to reopen the same file outside an if()

Re: delete and MmFile

2012-01-28 Thread NewName
Thanks Daniel. So clear() is a function thing, so my delete mmf; will look like clear(mmf); am I right?

Re: A tutorial on D templates: updates

2012-01-29 Thread NewName
I'm learning D. So thanks for the tutorial. I hope D becomes more popular, as it deserves.

Does D supply basic error codes?

2012-01-29 Thread NewName
Hello all. C has EXIT_FAILURE and EXIT_SUCCESS to be returned from main(). Does D have similar predefined values?

regex: force entire string to match

2012-01-31 Thread NewName
Hello all. I want to write a regex to check if a whole string is a number. With my current regex([0-9]+) numbers will be carved out of things like aaa456 (hit: 456) and I circumvent this by checking the lengths for inequality, which is stupid. My regex is surely missing something? Thank you for

Re: regex: force entire string to match

2012-01-31 Thread NewName
You want to match the beginning and end of the input as well: ^[0-9]+$ Thanks.