Re: Beta D 2.071.0-b2

2016-03-31 Thread Jacob Carlborg via Digitalmars-d-announce

On 2016-03-31 21:21, Steven Schveighoffer wrote:


Right, so definitely a bug in the compiler. The -transition=checkimports
flag is supposed to tell you about changes in behavior between the prior
regime (achieved with -transition=import) and the current regime.

-Steve


Reported two bugs:

https://issues.dlang.org/show_bug.cgi?id=15857
https://issues.dlang.org/show_bug.cgi?id=15856

--
/Jacob Carlborg


Re: Blog article on new import changes

2016-03-31 Thread xenon325 via Digitalmars-d-announce
On Wednesday, 30 March 2016 at 12:58:00 UTC, Steven Schveighoffer 
wrote:

Sound better?


Yeah, thanks.

Not sure if it's worth it to repeat after each example. Feels 
redundant.


I think it's important to state the previous and new behavior, 
even though it's always the same. It does sound redundant, but 
makes it easier to understand.


That's reasonable. You could kinda "compress" this, however - 
full description on first occurrence and a brief one later on. 
This is a common practice AFAICT:


With 2.070 and prior versions, compiling this works just fine. 
With 2.071 and above, you will get either a deprecation 
warning, or an error.


--> "With 2.070 and prior versions, compiling this works just 
fine. In 2.071 it's deprecated (meaning you will get a warning 
now and compilation error with some later version of the 
compiler)"


With 2.070, this compiled just fine. However, printf is 
supposed to be a private symbol of module ex2_a. With 2.071 and 
above, this will trigger a deprecation warning. In the future, 
the code will trigger an error.


--> "Fine with 2.070, deprecated in 2.071 because printf is 
supposed to be a private symbol of module ex2_a"


In 2.070, this produces no warning or error. In 2.071 and 
beyond, this will produce a deprecation warning, and eventually 
an error.


--> "Fine with 2.070, deprecated in 2.071"


Anyway, not a big deal. Sorry if I've gone too far with 
nitpicking :) Thanks for the article!


-Alexander


Units of Measurement Library: units-d

2016-03-31 Thread Nordlöw via Digitalmars-d-announce

I've put David Nadlinger work together with my tweaks on top at

https://github.com/nordlow/units-d

to make it easier to experiment with.

PR are very welcome.


Re: Beta D 2.071.0-b2

2016-03-31 Thread Steven Schveighoffer via Digitalmars-d-announce

On 3/31/16 3:15 PM, Jacob Carlborg wrote:

On 2016-03-31 16:59, Steven Schveighoffer wrote:

The compiler. Your first post has a deprecation indicating it found a
symbol twice in the same place :) The second seems like there should be
no issues. I assume it compiles identically both with and without
-transition=import? If that's the case, there should be no message.


Both examples compile the same with and without -transition=import. The
issues only appear with the -transition=checkimports flag enabled.



Right, so definitely a bug in the compiler. The -transition=checkimports 
flag is supposed to tell you about changes in behavior between the prior 
regime (achieved with -transition=import) and the current regime.


-Steve


Re: Beta D 2.071.0-b2

2016-03-31 Thread Jacob Carlborg via Digitalmars-d-announce

On 2016-03-31 16:59, Steven Schveighoffer wrote:

The compiler. Your first post has a deprecation indicating it found a
symbol twice in the same place :) The second seems like there should be
no issues. I assume it compiles identically both with and without
-transition=import? If that's the case, there should be no message.


Both examples compile the same with and without -transition=import. The 
issues only appear with the -transition=checkimports flag enabled.


--
/Jacob Carlborg


Re: Beta D 2.071.0-b2

2016-03-31 Thread Steven Schveighoffer via Digitalmars-d-announce

On 3/31/16 10:29 AM, Jacob Carlborg wrote:

On 2016-03-31 15:21, Steven Schveighoffer wrote:


These sure seem like bugs (including your other post).


In my code or in the compiler?


The compiler. Your first post has a deprecation indicating it found a 
symbol twice in the same place :) The second seems like there should be 
no issues. I assume it compiles identically both with and without 
-transition=import? If that's the case, there should be no message.


-Steve


Re: Beta D 2.071.0-b2

2016-03-31 Thread Jacob Carlborg via Digitalmars-d-announce

On 2016-03-31 15:21, Steven Schveighoffer wrote:


These sure seem like bugs (including your other post).


In my code or in the compiler?


The repetition (in case you are wondering) is because the compiler
prints a message for every usage of a symbol. In this case, you defined
two symbols, so you get two deprecation messages.

Note these aren't error messages, you should still get a binary.


Yeah, deprecation messages.

--
/Jacob Carlborg


Re: Beta D 2.071.0-b2

2016-03-31 Thread Steven Schveighoffer via Digitalmars-d-announce

On 3/31/16 3:22 AM, Jacob Carlborg wrote:

On 2016-03-30 13:03, Martin Nowak wrote:

Second beta for the 2.071.0 release.


I've found other confusing error messages. Compiling the following code:

class Foo
{
 import core.stdc.config;

 struct Bar
 {
 c_long a, b; // line 7
 }
}

With the -transition=checkimports flag gives the following error messages:

main.d(1): Deprecation: class main.Foo alias core.stdc.config.c_long
found in local import
main.d(7): Deprecation: local import search method found nothing (null)
instead of alias core.stdc.config.c_long
main.d(1): Deprecation: class main.Foo alias core.stdc.config.c_long
found in local import
main.d(7): Deprecation: local import search method found nothing (null)
instead of alias core.stdc.config.c_long



These sure seem like bugs (including your other post).

The repetition (in case you are wondering) is because the compiler 
prints a message for every usage of a symbol. In this case, you defined 
two symbols, so you get two deprecation messages.


Note these aren't error messages, you should still get a binary.

-Steve


Re: Blog article on new import changes

2016-03-31 Thread Steven Schveighoffer via Digitalmars-d-announce

On 3/30/16 3:24 PM, Walter Bright wrote:

On 3/30/2016 5:58 AM, Steven Schveighoffer wrote:

Thanks for the feedback.


And thanks for writing the article. Much appreciated.



You're welcome :)

-Steve


Re: Small rdmd wrapper for windows

2016-03-31 Thread Kagamin via Digitalmars-d-announce
Maybe rdmd should parse D_INCLUDE_PATH itself? Then it would work 
on its own.


Re: Small rdmd wrapper for windows

2016-03-31 Thread Steve Biedermann via Digitalmars-d-announce
On Wednesday, 30 March 2016 at 13:26:48 UTC, Steve Biedermann 
wrote:

Hi,

I made a simple wrapper around rdmd, which can be used to make 
.d files executable on windows and supports import paths. (A 
bat and a .d file)


Not really a big announcement, but maybe useful to some of you.

https://github.com/hardliner66/rdmd_windows


Short Update:
There is now a setup package available:
https://github.com/hardliner66/rdmd_windows/releases/tag/v1.0

Also, there is a setup package, which also installs dmd.


Re: Beta D 2.071.0-b2

2016-03-31 Thread Jacob Carlborg via Digitalmars-d-announce

On 2016-03-30 13:03, Martin Nowak wrote:

Second beta for the 2.071.0 release.


I've found other confusing error messages. Compiling the following code:

class Foo
{
import core.stdc.config;

struct Bar
{
c_long a, b; // line 7
}
}

With the -transition=checkimports flag gives the following error messages:

main.d(1): Deprecation: class main.Foo alias core.stdc.config.c_long 
found in local import
main.d(7): Deprecation: local import search method found nothing (null) 
instead of alias core.stdc.config.c_long
main.d(1): Deprecation: class main.Foo alias core.stdc.config.c_long 
found in local import
main.d(7): Deprecation: local import search method found nothing (null) 
instead of alias core.stdc.config.c_long


--
/Jacob Carlborg