move eqIdent to vm.nim (#7585)

* Strutils comment changes.

* fix typo
This commit is contained in:
Arne Döring 2018-04-15 23:38:43 +02:00 • committed by Andreas Rumpf
commit ed5b7cbac0
7 changed files with 132 additions and 41 deletions

View file

@ -45,8 +45,10 @@ proc endsWith*(s, suffix: cstring): bool {.noSideEffect,
proc cmpIgnoreStyle*(a, b: cstring): int {.noSideEffect,
rtl, extern: "csuCmpIgnoreStyle".} =
## Compares two strings normalized (i.e. case and
## underscores do not matter). Returns:
## Semantically the same as ``cmp(normalize($a), normalize($b))``. It
## is just optimized to not allocate temporary strings. This should
## NOT be used to compare Nim identifier names. use `macros.eqIdent`
## for that. Returns:
##
## | 0 iff a == b
## | < 0 iff a < b