gbdev / gbdev/rgbds

[Feature request] Case-insensitive string comparison operator

Open
#1,884 8 comments 1 reaction 0 assignees View on GitHub
enhancement rgbasm
Dominant language
C++
Stars
1.6k
Forks
193
Avg merge
22h 17m
Merged PRs (30d)
26

Description

We have `===` and `!==`, which are terser than `STRCMP`, but there's still a common idiom of doing case-insensitive comparisons, usually for instruction-like macros (e.g. `strlwr("\1") === "hl"` or `strupr("\1") === "HL"`, doesn't matter which).

It could be `~==`, e.g. `"\1" ~== "hl"`. (And don't bother with a "compare case-insensitively different" operator, something like "`!~=`" or "`~!=`" or even "`!~==`" would be ugly and too rare to bother.)

Contributor guide

Open the contributing guide

Research direction

The issue proposes a new case-insensitive string comparison operator, using examples with strlwr, strupr, ===, !==, and STRCMP. No implementation files, tests, or entry points are named, so first locate the existing comparison-operator handling and its tests; done should include an agreed operator syntax and coverage for case-insensitive comparisons.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
compilers
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.