www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 7494] New: Selective import does not work inside a function

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494

           Summary: Selective import does not work inside a function
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: rejects-valid
          Severity: regression
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: kennytm gmail.com


--- Comment #0 from kennytm gmail.com 2012-02-13 08:27:27 PST ---
Test case:

======================
void test7494()
{
    import core.bitop : bsr;
    // ^ or just any selective import statements
    bsr(1);
}
======================

Compiling with 'dmd -c test.d' gives

    Error: undefined identifier bsr

The error was introduced in commit c022036c8f9fea1672bb2c56edd610715f6335c8
(for fixing bug 314).

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Feb 13 2012
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494


dawg dawgfoto.de changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dawg dawgfoto.de


--- Comment #1 from dawg dawgfoto.de 2012-02-13 09:38:05 PST ---
*** Issue 7495 has been marked as a duplicate of this issue. ***

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Feb 13 2012
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494


dawg dawgfoto.de changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|regression                  |major


--- Comment #2 from dawg dawgfoto.de 2012-02-13 09:38:54 PST ---
It's not a regression though. This is 2.057 behavior.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Feb 13 2012
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494


Walter Bright <bugzilla digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bugzilla digitalmars.com


--- Comment #3 from Walter Bright <bugzilla digitalmars.com> 2012-02-13
17:59:00 PST ---
Why is this marked as major?

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Feb 13 2012
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494


dawg dawgfoto.de changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Severity|major                       |normal


--- Comment #4 from dawg dawgfoto.de 2012-02-13 18:14:20 PST ---
It was filed as a regression.
But it's a regression against 2.058git not against 2.057.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Feb 13 2012
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494


Stewart Gordon <smjg iname.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |smjg iname.com


--- Comment #5 from Stewart Gordon <smjg iname.com> 2012-02-14 14:14:09 PST ---
Affects unittests as well.  Probably part of the same bug.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Feb 14 2012
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494


bearophile_hugs eml.cc changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bearophile_hugs eml.cc


--- Comment #6 from bearophile_hugs eml.cc 2012-02-18 12:55:34 PST ---
Now this compiles:

void main() {
    import std.stdio: writeln;
}


While here it doesn't find writeln():

void main() {
    import std.stdio: writeln;
    writeln(1);
}

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Feb 18 2012
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494



--- Comment #7 from SomeDude <lovelydear mailmetrash.com> 2012-04-21 06:07:41
PDT ---
*** Issue 7622 has been marked as a duplicate of this issue. ***

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Apr 21 2012
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494


Kenji Hara <k.hara.pg gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |pull


--- Comment #8 from Kenji Hara <k.hara.pg gmail.com> 2012-06-07 04:46:01 PDT ---
https://github.com/D-Programming-Language/dmd/pull/990

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jun 07 2012
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494



--- Comment #9 from github-bugzilla puremagic.com 2012-06-11 11:59:47 PDT ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/f2c47c247fced50aa01a9e65fc48fc28d623c422
fix Issue 7494 - Selective import does not work inside a function

https://github.com/D-Programming-Language/dmd/commit/0c6353c61fe157ff699e5dcc7fa16250b9d3ef67
Merge pull request #990 from 9rnsr/fix7494

Issue 7494 - Selective import does not work inside a function

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jun 11 2012
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494


Walter Bright <bugzilla digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED


-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jun 11 2012
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=7494


Kenji Hara <k.hara.pg gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ellery-newcomer utulsa.edu


--- Comment #10 from Kenji Hara <k.hara.pg gmail.com> 2012-06-29 21:48:47 PDT
---
*** Issue 8319 has been marked as a duplicate of this issue. ***

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Jun 29 2012