Skip to content

When heredoc content is between symbol begin colon and symbol content, colorizing is wrong #740

Closed

Description

@tompng

Description

Combination with heredoc and \, heredoc content can be placed between symbol beginning : and symbol content.

<<HEREDOC; :\
heredoc
HEREDOC
symbol

Colorizing such code is wrong.

puts IRB::Color.colorize_code "<<A;:\\\na\nA\nsymbol"

heredo_symbol

Result of irb_info

Ruby version: 3.2.2
IRB version: irb 1.8.3 (2023-10-14)
InputMethod: RelineInputMethod with Reline 0.3.9 and /Users/tomoya.ishida/.inputrc
.irbrc path: /Users/tomoya.ishida/.irbrc
RUBY_PLATFORM: arm64-darwin22
LANG env: ja_JP.UTF-8
East Asian Ambiguous Width: 1

Terminal Emulator

any

Setting Files

no

Activity

  1. tompng commented on Jan 23, 2026

    @tompng
    MemberAuthor

    Fixed with #1091

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions