<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ruby.git/lib/irb/source_finder.rb, branch v3_4_9</title>
<subtitle>The Ruby Programming Language</subtitle>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/'/>
<entry>
<title>[ruby/irb] Don't show 'Maybe IRB bug!' in show_source and ls command</title>
<updated>2024-12-03T21:55:33+00:00</updated>
<author>
<name>tomoya ishida</name>
<email>tomoyapenguin@gmail.com</email>
</author>
<published>2024-12-03T21:55:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=e539342f65e468fc7f926277eff61cb8b8a60622'/>
<id>e539342f65e468fc7f926277eff61cb8b8a60622</id>
<content type='text'>
(https://github.com/ruby/irb/pull/1039)

https://github.com/ruby/irb/commit/9eb14a3a0b
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/irb/pull/1039)

https://github.com/ruby/irb/commit/9eb14a3a0b
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/irb] Use InstructionSequence#script_lines to get method source</title>
<updated>2024-09-16T17:36:27+00:00</updated>
<author>
<name>tomoya ishida</name>
<email>tomoyapenguin@gmail.com</email>
</author>
<published>2024-09-16T17:36:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=6c4ce72609396cff8970c0fdebbfa190ec75ece1'/>
<id>6c4ce72609396cff8970c0fdebbfa190ec75ece1</id>
<content type='text'>
(https://github.com/ruby/irb/pull/1005)

It works with both prism and parse.y

https://github.com/ruby/irb/commit/bcfaa72d5a
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/irb/pull/1005)

It works with both prism and parse.y

https://github.com/ruby/irb/commit/bcfaa72d5a
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/irb] Improve constant lookup in SourceFinder</title>
<updated>2024-02-14T13:46:49+00:00</updated>
<author>
<name>tomoya ishida</name>
<email>tomoyapenguin@gmail.com</email>
</author>
<published>2024-02-14T13:46:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=d0412599e08283430ca0a3c34f2e58eb5c5d5619'/>
<id>d0412599e08283430ca0a3c34f2e58eb5c5d5619</id>
<content type='text'>
(https://github.com/ruby/irb/pull/871)

https://github.com/ruby/irb/commit/87c279ccf2
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/irb/pull/871)

https://github.com/ruby/irb/commit/87c279ccf2
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/irb] Fix SourceFinder's constant evaluation issue</title>
<updated>2024-02-13T13:36:32+00:00</updated>
<author>
<name>Stan Lo</name>
<email>stan001212@gmail.com</email>
</author>
<published>2024-02-13T13:36:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=2f0f95235a1de489f50c7a9dbe3477f9f7e60cd1'/>
<id>2f0f95235a1de489f50c7a9dbe3477f9f7e60cd1</id>
<content type='text'>
(https://github.com/ruby/irb/pull/869)

Currently, if the signature's constant part is not defined, a NameError
would be raised.

```
irb(main):001&gt; show_source Foo
(eval):1:in `&lt;top (required)&gt;': uninitialized constant Foo (NameError)

Foo
^^^
        from (irb):1:in `&lt;main&gt;'
```

This commit fixes the issue and simplifies the `edit` command's implementation.

https://github.com/ruby/irb/commit/8c16e029d1
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/irb/pull/869)

Currently, if the signature's constant part is not defined, a NameError
would be raised.

```
irb(main):001&gt; show_source Foo
(eval):1:in `&lt;top (required)&gt;': uninitialized constant Foo (NameError)

Foo
^^^
        from (irb):1:in `&lt;main&gt;'
```

This commit fixes the issue and simplifies the `edit` command's implementation.

https://github.com/ruby/irb/commit/8c16e029d1
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/irb] Refactor eval_path and `SourceFinder::Source`</title>
<updated>2024-02-13T13:33:36+00:00</updated>
<author>
<name>Stan Lo</name>
<email>stan001212@gmail.com</email>
</author>
<published>2024-02-13T13:33:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=ec26786b1a37350c0ff21666b028ec5e2aa6a318'/>
<id>ec26786b1a37350c0ff21666b028ec5e2aa6a318</id>
<content type='text'>
(https://github.com/ruby/irb/pull/870)

* Assign `@eval_path` through `irb_path=` method

This simplifies the original caching logic for the `eval_path` method
and makes it easier to understand.

* Refactor SourceFinder::Source

https://github.com/ruby/irb/commit/c63e4c4035
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/irb/pull/870)

* Assign `@eval_path` through `irb_path=` method

This simplifies the original caching logic for the `eval_path` method
and makes it easier to understand.

* Refactor SourceFinder::Source

https://github.com/ruby/irb/commit/c63e4c4035
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/irb] Powerup show_source by enabling RubyVM.keep_script_lines</title>
<updated>2024-02-12T18:38:30+00:00</updated>
<author>
<name>tomoya ishida</name>
<email>tomoyapenguin@gmail.com</email>
</author>
<published>2024-02-12T18:38:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=7af97dc71fd6790a3f4ffe47dcc5720b675f6b6b'/>
<id>7af97dc71fd6790a3f4ffe47dcc5720b675f6b6b</id>
<content type='text'>
(https://github.com/ruby/irb/pull/862)

* Powerup show_source by enabling RubyVM.keep_script_lines

* Add file_content field to avoid reading file twice while show_source

* Change path passed to eval, don't change irb_path.

* Encapsulate source coloring logic and binary file check insode class Source

* Add edit command testcase when irb_path does not exist

* Memoize irb_path existence to reduce file existence check calculating eval_path

https://github.com/ruby/irb/commit/239683a937
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/irb/pull/862)

* Powerup show_source by enabling RubyVM.keep_script_lines

* Add file_content field to avoid reading file twice while show_source

* Change path passed to eval, don't change irb_path.

* Encapsulate source coloring logic and binary file check insode class Source

* Add edit command testcase when irb_path does not exist

* Memoize irb_path existence to reduce file existence check calculating eval_path

https://github.com/ruby/irb/commit/239683a937
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/irb] Make SourceFinder ignore binary sources</title>
<updated>2024-01-08T12:42:39+00:00</updated>
<author>
<name>Stan Lo</name>
<email>stan001212@gmail.com</email>
</author>
<published>2024-01-08T12:42:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=8f4eda50921f9adc20df3138208e8ebd0e7d582e'/>
<id>8f4eda50921f9adc20df3138208e8ebd0e7d582e</id>
<content type='text'>
(https://github.com/ruby/irb/pull/836)

https://github.com/ruby/irb/commit/73b35bb7f4
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/irb/pull/836)

https://github.com/ruby/irb/commit/73b35bb7f4
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/irb] Make show_source resolve top-level constant names</title>
<updated>2024-01-01T17:40:38+00:00</updated>
<author>
<name>Stan Lo</name>
<email>stan001212@gmail.com</email>
</author>
<published>2024-01-01T17:40:35+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=676748abcad62c021fc122d137f177d3c0f0f7a8'/>
<id>676748abcad62c021fc122d137f177d3c0f0f7a8</id>
<content type='text'>
(https://github.com/ruby/irb/pull/831)

https://github.com/ruby/irb/commit/5843616c78
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/irb/pull/831)

https://github.com/ruby/irb/commit/5843616c78
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/irb] Simplify show_source's super calculation</title>
<updated>2023-12-10T04:21:46+00:00</updated>
<author>
<name>Stan Lo</name>
<email>stan001212@gmail.com</email>
</author>
<published>2023-12-10T04:21:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=130268e264f59c037eda31205c6e2223cffafbbe'/>
<id>130268e264f59c037eda31205c6e2223cffafbbe</id>
<content type='text'>
(https://github.com/ruby/irb/pull/807)

https://github.com/ruby/irb/commit/2cccc448de
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
(https://github.com/ruby/irb/pull/807)

https://github.com/ruby/irb/commit/2cccc448de
</pre>
</div>
</content>
</entry>
<entry>
<title>[ruby/irb] Change show_source tests into integration tests</title>
<updated>2023-11-28T17:22:46+00:00</updated>
<author>
<name>Peter Zhu</name>
<email>peter@peterzhu.ca</email>
</author>
<published>2023-11-28T17:22:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.ruby-lang.org/ruby.git/commit/?id=fadd28c7ba6b55ec934f379cfc30a8111e340404'/>
<id>fadd28c7ba6b55ec934f379cfc30a8111e340404</id>
<content type='text'>
* Remove trailing spaces

* Migrate show_source tests to integration tests

Because show_source tests often need to define class and/or methods,
they can easily leak state to other tests. Changing them to integration
tests will ensure that they are run in a clean environment.

* Fix NoMethodError caused by SourceFinder#method_target

https://github.com/ruby/irb/commit/3c39f13397c72a8db24e50afdcb8942e6c4ea12f
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* Remove trailing spaces

* Migrate show_source tests to integration tests

Because show_source tests often need to define class and/or methods,
they can easily leak state to other tests. Changing them to integration
tests will ensure that they are run in a clean environment.

* Fix NoMethodError caused by SourceFinder#method_target

https://github.com/ruby/irb/commit/3c39f13397c72a8db24e50afdcb8942e6c4ea12f
</pre>
</div>
</content>
</entry>
</feed>
