[#72745] [Ruby trunk - Misc #11876] [Closed] Scheduled maintenance 2016/01/01 — shibata.hiroshi@...
Issue #11876 has been updated by Hiroshi SHIBATA.
shibata.hiroshi@gmail.com wrote:
[#72824] [Ruby trunk - Bug #11973] IO#advise should raise NotImplementedError on platforms that do not support that call — git@...
Issue #11973 has been updated by Chuck Remes.
[#72954] [Ruby trunk - Feature #12010] [Assigned] Exclude dot and dotdot from Dir#each — naruse@...
Issue #12010 has been reported by Yui NARUSE.
naruse@airemix.jp wrote:
[#73313] [Ruby trunk - Bug #12007] [Open] Newly added Unicode data file doesn't get downloaded — shugo@...
Issue #12007 has been updated by Shugo Maeda.
[#73372] [Ruby trunk - Misc #12004] Code of Conduct — benton@...
Issue #12004 has been updated by Benton Barnett.
On Sun, Jan 24, 2016 at 5:13 PM, <benton@bentonbarnett.com> wrote:
[#73421] [Ruby trunk - Misc #12004] Code of Conduct — nekocat432@...
Issue #12004 has been updated by Ruby Dino.
I’m sorry, but this, like the code of merit, is merely a derailing tactic.
On 2016/01/26 01:32, Austin Ziegler wrote:
On Tue, Jan 26, 2016 at 12:25 AM, Martin J. Dürst <duerst@it.aoyama.ac.jp>
[#73491] [Ruby trunk - Misc #12004] Code of Conduct — git@...
Issue #12004 has been updated by Chuck Remes.
They will never provide any numbers because they are not engineers and they
Coraline is a panelist on Ruby rogues and a very well respected member of
OK, sorry for previous comment. Let's try this way.
On Tue, Jan 26, 2016 at 5:15 PM, Andrew Kirilenko <
[#73558] [Ruby trunk - Misc #12004] Code of Conduct — andrew.kirilenko@...
Issue #12004 has been updated by Andrew Kirilenko.
Andrew, please stop digging. Your hole is only getting deeper.
>Andrew, please stop digging. Your hole is only getting deeper.
[#73586] [Ruby trunk - Misc #12004] Code of Conduct — andrew@...
Issue #12004 has been updated by Andrew Vit.
[#73593] [Ruby trunk - Bug #12034] RegExp does not respect file encoding directive — nobu@...
Issue #12034 has been updated by Nobuyoshi Nakada.
[ruby-core:72985] [Ruby trunk - Feature #9992] Access Modifiers (Internal Interfaces)
Issue #9992 has been updated by Jörg W Mittag.
I'm having trouble understanding what you mean by *namespace*. Classes and modules don't belong to namespaces. *Constants* belong to *modules*, but the fact that two classes which may or may not be referenced by two constants which are namespaced in the same module does not imply any sort of relationship whatsoever between either the two classes or one of the classes and the module.
Expanding your example a bit:
~~~ruby
module Foo; end
Baz = Bar = Foo
class Foo::Bar
def baz
puts ‘baz’
end
internal :baz
end
class Bar::Qux
def baz
::Baz::Bar.new.baz
end
end
~~~
Should it work? If not, why? The modules and classes involved are the *exact* same ones as in your example.
I mean, what about this:
~~~ruby
foo = Class.new
bar = Class.new
baz = Module.new
baz.const_set(:Foo, foo)
baz.const_set(:Bar, bar)
quux = Module.new
quux.const_set(:Goobledigook, foo)
quux.const_set(:Blahdiblah, bar)
baz.send(:remove_const, :Bar)
module One; module Two; end end
One::Two::Three = quux::Goobledigook
~~~
Okay, now what namespace relations are there?
If I now do this:
~~~ruby
class One::Two::Three
internal def blub; end
end
~~~
Am I allowed to call `foo.new.blub` from a method in `quux::Blahdiblah`?
----------------------------------------
Feature #9992: Access Modifiers (Internal Interfaces)
https://bugs.ruby-lang.org/issues/9992#change-56205
* Author: Daniel Ferreira
* Status: Open
* Priority: Normal
* Assignee:
----------------------------------------
Hi,
I’m would like to discuss with you the concept of Internal Interfaces.
Currently ruby offers three access modifiers choices to set methods visibility:
- public
- protected
- private
Public methods define what we may call the Public Interface.
Private methods are private to the class and its subclasses.
Protected methods are public for the subclasses.
I would like to work with a new access modifier that would allow the creation of Internal methods.
Internal methods would be object methods that could only be called within the namespace.
Ex:
~~~ruby
module Foo; end
class Foo::Bar
def baz
puts ‘baz’
end
internal :baz
end
class Foo::Qux
def baz
::Foo::Bar.new.baz
end
end
~~~
Is this something that we can think about in a future implementation of ruby?
An extra feature that would not break backward compatibility.
Cheers,
Daniel
--
https://bugs.ruby-lang.org/
Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>