July 09, 2011
RDMD from beta2:
rdmd build 20110706
Usage: rdmd [RDMD AND DMD OPTIONS]... program [PROGRAM OPTIONS]...
Builds (with dependents) and runs a D program.
Example: rdmd -release myprog --myprogparm 5

Any option to be passed to dmd must occur before the program name. In addition
to dmd options, rdmd recognizes the following options:
  --build-only      just build the executable, don't run it
  --chatty          write dmd commands to stdout before executing them
  --compiler=comp   use the specified compiler (e.g. gdmd) instead of dmd
  --dry-run         do not compile, just show what commands would be run
                      (implies --chatty)
  --eval=code       evaluate code ?? la perl -e (multiple --eval allowed)
  --force           force a rebuild even if apparently not necessary
  --help            this message
  --loop            assume "foreach (line; stdin.byLine()) { ... }" for eval
  --main            add a stub main program to the mix (e.g. for unittesting)
  --makedepend      print dependencies in makefile format and exit
  --man             open web browser on manual page
  --shebang         rdmd is in a shebang line (put as first argument)

github:
rdmd build 20110708
Usage: rdmd [RDMD AND DMD OPTIONS]... program [PROGRAM OPTIONS]...
Builds (with dependents) and runs a D program.
Example: rdmd -release myprog --myprogparm 5

Any option to be passed to dmd must occur before the program name. In addition
to dmd options, rdmd recognizes the following options:
  --build-only      just build the executable, don't run it
  --chatty          write dmd commands to stdout before executing them
  --compiler=comp   use the specified compiler (e.g. gdmd) instead of dmd
  --dry-run         do not compile, just show what commands would be run
                      (implies --chatty)
  --eval=code       evaluate code ?? la perl -e (multiple --eval allowed)
  --force           force a rebuild even if apparently not necessary
  --help            this message
  --loop            assume "foreach (line; stdin.byLine()) { ... }" for eval
  --main            add a stub main program to the mix (e.g. for unittesting)
  --makedepend      print dependencies in makefile format and exit
  --man             open web browser on manual page
  --shebang         rdmd is in a shebang line (put as first argument)

The dates are different but that doesn't matter it picks that up during compilation.



>From what I can tell the RDMD in beta2 seems to compile the module,
but it doesn't run it.

Here's another example:
import std.stdio;
void main()
{
	auto file = File("bla.txt", "w");
}

> dmd2beta_rdmd.exe test.d
Stops RDMD in the console and nothing happens. I have to hit enter twice, then test.d.deps appears but no bla.txt.

> github_rdmd.exe test.d
Works as expected, a "bla.txt" file is written to the current folder.

I've used the dmd2 beta itself to compile RDMD from github, the latest revision (commit 6085e8521653ea031508 - "Fix complaint about nonexistent directory in dry-run mode").

Compiled it with `DMD rdmd.d`.
July 08, 2011
I can reproduce the problem. The only thing I can think of is druntime/phobos have been changing.

July 08, 2011

On 7/8/2011 11:07 PM, Walter Bright wrote:
> I can reproduce the problem. The only thing I can think of is druntime/phobos have been changing.
>
>

Pulling the latest druntime & phobos does not fix it.

I have no idea where it's going wrong.

Can you build rdmd with the beta?
July 09, 2011
Ok first there was a lot of confusion from my part because I pulled RDMD and then I was walking through the changesets until I got a build of RDMD that works. I mistakenly thought it was the latest changeset, but I was wrong.

*Fresh start*:
Using beta2, here's a combination of my MSYS and console log, and also
I've added a test.d file into the tools directory which creates a
"foo.txt" file:

MSYS:
$ git clone https://github.com/D-Programming-Language/tools.git
Cloning into tools...
remote: Counting objects: 105, done.
remote: Compressing objects: 100% (42/42), done.
remote: Total 105 (delta 32), reused 102 (delta 29)
Receiving objects: 100% (105/105), 19.57 KiB, done.
Resolving deltas: 100% (32/32), done.

Andrej at EXPERIEN-2EE899 /d/dev/projects
$ cd tools

CONSOLE:
D:\dev\projects\tools>dmd rdmd.d
D:\dev\projects\tools>rdmd.exe test.d

Creates test.d.deps but no foo.txt file.

MSYS:
$ git checkout HEAD^
Note: checking out 'HEAD^'.

HEAD is now at 6085e85... Fix complaint about nonexistent directory in dry-run m ode

CONSOLE:
D:\dev\projects\tools>dmd rdmd.d
D:\dev\projects\tools>rdmd.exe test.d

Again, test.d.deps is generated but no foo.txt file.

MSYS:
$ git checkout HEAD^
Previous HEAD position was 6085e85... Fix complaint about nonexistent directory
in dry-run mode
HEAD is now at e27d9b9... Merge branch 'makedepend'

CONSOLE:
D:\dev\projects\tools>dmd rdmd.d
D:\dev\projects\tools>rdmd.exe test.d

Now the foo.txt file is actually generated.

RDMD with the two last changesets doesn't even seem to compile the module properly, as no errors are generated on wrong code. It only creates a .deps file.

So, this does seem to be a case of a broken changeset, probably 6085e85.
July 09, 2011
I'm pretty sure this is a bug in the DMD beta. First of all, the seemingly-offending changeset in rdmd doesn't look like it should even possibly have this effect. Secondly, I can reproduce Andrej's problem using the DMD beta, but the problem goes away if I use 2.053:

*Fresh start*:

[Unzipped Andrej's rdmd_bug.zip to "D:\DevTool\rdmd_bug"]

D:\DevTool\rdmd_bug>dmd
DMD32 D Compiler v2.053
[...snip...]

D:\DevTool\rdmd_bug>git clone
https://github.com/D-Programming-Language/tools.git
Cloning into tools...
[...snip...]

D:\DevTool\rdmd_bug>copy test.d tools
        1 file(s) copied.

D:\DevTool\rdmd_bug>cd tools

D:\DevTool\rdmd_bug\tools>dmd rdmd.d

D:\DevTool\rdmd_bug\tools>rdmd test.d
test

D:\DevTool\rdmd_bug\tools>SET PATH=D:\DevTool\dmd2beta\dmd2\windows\bin;%PATH%

D:\DevTool\rdmd_bug\tools>dmd
DMD32 D Compiler v2.054
[...snip...]

D:\DevTool\rdmd_bug\tools>dmd rdmd.d

D:\DevTool\rdmd_bug\tools>rdmd test.d

D:\DevTool\rdmd_bug\tools>


----- Original Message ----- 
From: "Andrej Mitrovic" <andrej.mitrovich at gmail.com>
To: "Discuss the dmd beta releases for D" <dmd-beta at puremagic.com>
Sent: Saturday, July 09, 2011 10:15 AM
Subject: Re: [dmd-beta] dmd 1.069 and 2.054 beta


> Ok first there was a lot of confusion from my part because I pulled RDMD and then I was walking through the changesets until I got a build of RDMD that works. I mistakenly thought it was the latest changeset, but I was wrong.
>
> *Fresh start*:
> Using beta2, here's a combination of my MSYS and console log, and also
> I've added a test.d file into the tools directory which creates a
> "foo.txt" file:
>
> MSYS:
> $ git clone https://github.com/D-Programming-Language/tools.git
> Cloning into tools...
> remote: Counting objects: 105, done.
> remote: Compressing objects: 100% (42/42), done.
> remote: Total 105 (delta 32), reused 102 (delta 29)
> Receiving objects: 100% (105/105), 19.57 KiB, done.
> Resolving deltas: 100% (32/32), done.
>
> Andrej at EXPERIEN-2EE899 /d/dev/projects
> $ cd tools
>
> CONSOLE:
> D:\dev\projects\tools>dmd rdmd.d
> D:\dev\projects\tools>rdmd.exe test.d
>
> Creates test.d.deps but no foo.txt file.
>
> MSYS:
> $ git checkout HEAD^
> Note: checking out 'HEAD^'.
>
> HEAD is now at 6085e85... Fix complaint about nonexistent directory in
> dry-run m
> ode
>
> CONSOLE:
> D:\dev\projects\tools>dmd rdmd.d
> D:\dev\projects\tools>rdmd.exe test.d
>
> Again, test.d.deps is generated but no foo.txt file.
>
> MSYS:
> $ git checkout HEAD^
> Previous HEAD position was 6085e85... Fix complaint about nonexistent
> directory
> in dry-run mode
> HEAD is now at e27d9b9... Merge branch 'makedepend'
>
> CONSOLE:
> D:\dev\projects\tools>dmd rdmd.d
> D:\dev\projects\tools>rdmd.exe test.d
>
> Now the foo.txt file is actually generated.
>
> RDMD with the two last changesets doesn't even seem to compile the module properly, as no errors are generated on wrong code. It only creates a .deps file.
>
> So, this does seem to be a case of a broken changeset, probably 6085e85.
> _______________________________________________
> dmd-beta mailing list
> dmd-beta at puremagic.com
> http://lists.puremagic.com/mailman/listinfo/dmd-beta

July 09, 2011

On 7/9/2011 11:56 AM, Nick Sabalausky wrote:
> I'm pretty sure this is a bug in the DMD beta. First of all, the seemingly-offending changeset in rdmd doesn't look like it should even possibly have this effect. Secondly, I can reproduce Andrej's problem using the DMD beta, but the problem goes away if I use 2.053:
>

Yup, it works if compiled with 2.053. Sigh.
July 09, 2011
Time to visit the ol' assembly output? :)
July 09, 2011
Am 09.07.2011 21:27, schrieb Andrej Mitrovic:
> Time to visit the ol' assembly output? :)
> _______________________________________________
> dmd-beta mailing list
> dmd-beta at puremagic.com
> http://lists.puremagic.com/mailman/listinfo/dmd-beta
Or use git bisect ( http://progit.org/book/ch6-5.html ) to find the dmd commit which introduced the problem.

-- 
Johannes Pfau

1 2 3 4
Next ›   Last »