Skip to content

Conversation

@exoego
Copy link
Contributor

@exoego exoego commented Mar 28, 2025

Closes #19

  • Adds utils/halfwidth_katakana_to_hiragana.
    • Counterintuitively, this is not "half to full" conversion. Because, ..._to_hiragana util can be leveraged in to_hiragana's character loops so the input is not enumerated multiple times.
  • In to_katakana and to_romaji, the util is invoked only when input contains half-width kana,
    • The input may be fully enumerated at worst case when no half-width katakana is used.
  • to_haflwidth_katakana or new option is NOT added, since I don't need such.

@exoego
Copy link
Contributor Author

exoego commented Jun 13, 2025

@PSeitz Can you take a look 🙇

} else if is_char_halfwidth_katakana(input_char) {
let result = HALFWIDTH_KATAKANA_TO_HIRAGANA_NODE_TREE.get(&chars[index..]);
result.0.chars().for_each(|char| hira.push(char));
previous_read_forward_count += result.1 - 1;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't get this part I don't think it should have a dependency on the outer loop

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deleted in b92e381
I no longer remember why I added this...

@exoego exoego closed this by deleting the head repository Aug 13, 2025
@PSeitz
Copy link
Owner

PSeitz commented Aug 13, 2025

@exoego Was deleting the heap repo on purpose?

@exoego
Copy link
Contributor Author

exoego commented Aug 13, 2025

Reopend #21 since I deleted the head repo accidentally

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feature: hankaku-kana (half-width kana) support

2 participants